mirror of
https://github.com/Xaymar/obs-StreamFX
synced 2024-11-14 07:45:06 +00:00
project: Fix various catch-by-value locations
This commit is contained in:
parent
e887a53463
commit
c716e75ba3
2 changed files with 4 additions and 4 deletions
|
@ -161,7 +161,7 @@ void filter::blur::blur_factory::on_list_fill()
|
||||||
char* file = obs_module_file("effects/color-conversion.effect");
|
char* file = obs_module_file("effects/color-conversion.effect");
|
||||||
try {
|
try {
|
||||||
color_converter_effect = std::make_shared<gs::effect>(file);
|
color_converter_effect = std::make_shared<gs::effect>(file);
|
||||||
} catch (std::runtime_error ex) {
|
} catch (std::runtime_error& ex) {
|
||||||
P_LOG_ERROR("<filter-blur> Loading effect '%s' failed with error(s): %s", file, ex.what());
|
P_LOG_ERROR("<filter-blur> Loading effect '%s' failed with error(s): %s", file, ex.what());
|
||||||
}
|
}
|
||||||
bfree(file);
|
bfree(file);
|
||||||
|
@ -170,7 +170,7 @@ void filter::blur::blur_factory::on_list_fill()
|
||||||
char* file = obs_module_file("effects/mask.effect");
|
char* file = obs_module_file("effects/mask.effect");
|
||||||
try {
|
try {
|
||||||
mask_effect = std::make_shared<gs::effect>(file);
|
mask_effect = std::make_shared<gs::effect>(file);
|
||||||
} catch (std::runtime_error ex) {
|
} catch (std::runtime_error& ex) {
|
||||||
P_LOG_ERROR("<filter-blur> Loading effect '%s' failed with error(s): %s", file, ex.what());
|
P_LOG_ERROR("<filter-blur> Loading effect '%s' failed with error(s): %s", file, ex.what());
|
||||||
}
|
}
|
||||||
bfree(file);
|
bfree(file);
|
||||||
|
@ -318,7 +318,7 @@ filter::blur::blur_instance::blur_instance(obs_data_t* settings, obs_source_t* p
|
||||||
try {
|
try {
|
||||||
this->m_source_rt = std::make_shared<gs::rendertarget>(GS_RGBA, GS_ZS_NONE);
|
this->m_source_rt = std::make_shared<gs::rendertarget>(GS_RGBA, GS_ZS_NONE);
|
||||||
this->m_output_rt = std::make_shared<gs::rendertarget>(GS_RGBA, GS_ZS_NONE);
|
this->m_output_rt = std::make_shared<gs::rendertarget>(GS_RGBA, GS_ZS_NONE);
|
||||||
} catch (std::exception ex) {
|
} catch (std::exception& ex) {
|
||||||
P_LOG_ERROR("<filter-blur:%s> Failed to create rendertargets, error %s.", obs_source_get_name(m_self),
|
P_LOG_ERROR("<filter-blur:%s> Failed to create rendertargets, error %s.", obs_source_get_name(m_self),
|
||||||
ex.what());
|
ex.what());
|
||||||
}
|
}
|
||||||
|
|
|
@ -133,7 +133,7 @@ filter::dynamic_mask::dynamic_mask_instance::dynamic_mask_instance(obs_data_t* d
|
||||||
char* file = obs_module_file("effects/channel-mask.effect");
|
char* file = obs_module_file("effects/channel-mask.effect");
|
||||||
try {
|
try {
|
||||||
this->effect = std::make_shared<gs::effect>(file);
|
this->effect = std::make_shared<gs::effect>(file);
|
||||||
} catch (std::exception ex) {
|
} catch (std::exception& ex) {
|
||||||
P_LOG_ERROR("Loading channel mask effect failed with error(s):\n%s", ex.what());
|
P_LOG_ERROR("Loading channel mask effect failed with error(s):\n%s", ex.what());
|
||||||
}
|
}
|
||||||
assert(this->effect != nullptr);
|
assert(this->effect != nullptr);
|
||||||
|
|
Loading…
Reference in a new issue