MCPcopy Create free account
hub / github.com/WarmUpTill/SceneSwitcher / enumSceneItem

Function enumSceneItem

plugins/base/macro-condition-media.cpp:410–426  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

408}
409
410static bool enumSceneItem(obs_scene_t *, obs_sceneitem_t *item, void *ptr)
411{
412 auto *sources = reinterpret_cast<std::vector<OBSWeakSource> *>(ptr);
413
414 if (obs_sceneitem_is_group(item)) {
415 obs_scene_t *scene = obs_sceneitem_group_get_scene(item);
416 obs_scene_enum_items(scene, enumSceneItem, ptr);
417 }
418
419 auto source = obs_sceneitem_get_source(item);
420 if (IsMediaSource(source)) {
421 OBSWeakSourceAutoRelease weak =
422 obs_source_get_weak_source(source);
423 sources->emplace_back(weak);
424 }
425 return true;
426}
427
428void MacroConditionMedia::UpdateMediaSourcesOfSceneList()
429{

Callers

nothing calls this directly

Calls 1

IsMediaSourceFunction · 0.85

Tested by

no test coverage detected