mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-10-24 23:08:51 -04:00
UI: Fix studio mode always duplicating scene
If scene duplication mode is disabled and studio mode is turned on, it would always initially duplicate scene regardless of whether scene duplication mode was activated or not.
This commit is contained in:
1 parent
f3df14374f
commit
a071c03470
1 file changed
+10
-4
@@ -755,10 +755,16 @@ void OBSBasic::SetPreviewProgramMode(bool enabled)
|
||||
|
||||
OBSScene curScene = GetCurrentScene();
|
||||
|
||||
obs_scene_t *dup = obs_scene_duplicate(curScene, nullptr,
|
||||
editPropertiesMode ?
|
||||
OBS_SCENE_DUP_PRIVATE_COPY :
|
||||
OBS_SCENE_DUP_PRIVATE_REFS);
|
||||
obs_scene_t *dup;
|
||||
if (sceneDuplicationMode) {
|
||||
dup = obs_scene_duplicate(curScene, nullptr,
|
||||
editPropertiesMode ?
|
||||
OBS_SCENE_DUP_PRIVATE_COPY :
|
||||
OBS_SCENE_DUP_PRIVATE_REFS);
|
||||
} else {
|
||||
dup = curScene;
|
||||
obs_scene_addref(dup);
|
||||
}
|
||||
|
||||
obs_source_t *transition = obs_get_output_source(0);
|
||||
obs_source_t *dup_source = obs_scene_get_source(dup);
|
||||
|
||||
Reference in new issue
Block a user