filter-displacement: Don't crash if the file can't be found

Fixes a user reported issue where obs-studio began crashing out of nowhere.
This commit is contained in:
Michael Fabian 'Xaymar' Dirks 2019-04-23 17:20:07 +02:00
parent bbcde070f3
commit f6687c7ed6
1 changed files with 4 additions and 1 deletions

View File

@ -185,7 +185,10 @@ void filter::displacement::displacement_instance::validate_file_texture(std::str
do_update = !m_file_texture || do_update;
if (do_update) {
m_file_texture = std::make_shared<gs::texture>(m_file_name);
try {
m_file_texture = std::make_shared<gs::texture>(m_file_name);
} catch (...) {
}
}
}