From c706742097df2adf7d4b6d4f123a997cf1db0050 Mon Sep 17 00:00:00 2001 From: SuslikV Date: Mon, 4 Dec 2017 22:03:08 +0200 Subject: [PATCH] libobs: Fix scene filter duplication Scene filters were not being copied when a scene was duplicated with obs_scene_duplicate. Closes jp9000/obs-studio#1104 --- libobs/obs-scene.c | 2 ++ libobs/obs-source.c | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/libobs/obs-scene.c b/libobs/obs-scene.c index d35221288..2cbc2422f 100644 --- a/libobs/obs-scene.c +++ b/libobs/obs-scene.c @@ -1095,6 +1095,8 @@ obs_scene_t *obs_scene_duplicate(obs_scene_t *scene, const char *name, new_scene = make_private ? obs_scene_create_private(name) : obs_scene_create(name); + obs_source_copy_filters(new_scene->source, scene->source); + obs_data_apply(new_scene->source->private_settings, scene->source->private_settings); diff --git a/libobs/obs-source.c b/libobs/obs-source.c index d3a1e5b39..06ea82cc1 100644 --- a/libobs/obs-source.c +++ b/libobs/obs-source.c @@ -452,7 +452,6 @@ obs_source_t *obs_source_duplicate(obs_source_t *source, create_private ? OBS_SCENE_DUP_PRIVATE_COPY : OBS_SCENE_DUP_COPY); obs_source_t *new_source = obs_scene_get_source(new_scene); - duplicate_filters(new_source, source, create_private); return new_source; }