libobs: Make callback optional for obs_load_sources
Due to the ability to track creation of scenes via the "source_created" global signal, the callback parameter of obs_load_sources has become somewhat obsolete. This change allows the ability to pass NULL to the callback parameter in case the callback is not needed.
This commit is contained in:
parent
516c0de2e0
commit
8a1a02e7fc
@ -1642,6 +1642,7 @@ void obs_load_sources(obs_data_array_t *array, obs_load_source_cb cb,
|
|||||||
if (source->info.type == OBS_SOURCE_TYPE_TRANSITION)
|
if (source->info.type == OBS_SOURCE_TYPE_TRANSITION)
|
||||||
obs_transition_load(source, source_data);
|
obs_transition_load(source, source_data);
|
||||||
obs_source_load(source);
|
obs_source_load(source);
|
||||||
|
if (cb)
|
||||||
cb(private_data, source);
|
cb(private_data, source);
|
||||||
}
|
}
|
||||||
obs_data_release(source_data);
|
obs_data_release(source_data);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user