diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-03-08 14:11:42 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-03-08 14:11:42 +0300 |
commit | 49b9b159e4a4baaf48b121edf66d3436873dfc48 (patch) | |
tree | 58bb2669f7a5d5b776c94abcea3cedaadeb7750d /source/blender/makesrna | |
parent | cf09a2443cef60cda28c2c2023cb84728e644081 (diff) |
Fix T62317: missing Cycles viewport update when changing active camera.
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r-- | source/blender/makesrna/intern/rna_scene.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c index 6aec918f7f9..70cfa5604d4 100644 --- a/source/blender/makesrna/intern/rna_scene.c +++ b/source/blender/makesrna/intern/rna_scene.c @@ -659,12 +659,13 @@ void rna_Scene_set_update(Main *bmain, Scene *UNUSED(scene), PointerRNA *ptr) } } -static void rna_Scene_view3d_update(Main *bmain, Scene *UNUSED(scene_unused), PointerRNA *ptr) +static void rna_Scene_camera_update(Main *bmain, Scene *UNUSED(scene_unused), PointerRNA *ptr) { wmWindowManager *wm = bmain->wm.first; Scene *scene = (Scene *)ptr->data; WM_windows_scene_data_sync(&wm->windows, scene); + DEG_id_tag_update(&scene->id, ID_RECALC_COPY_ON_WRITE); } static void rna_Scene_fps_update(Main *UNUSED(bmain), Scene *scene, PointerRNA *UNUSED(ptr)) @@ -6387,7 +6388,7 @@ void RNA_def_scene(BlenderRNA *brna) RNA_def_property_flag(prop, PROP_EDITABLE); RNA_def_property_pointer_funcs(prop, NULL, NULL, NULL, "rna_Camera_object_poll"); RNA_def_property_ui_text(prop, "Camera", "Active camera, used for rendering the scene"); - RNA_def_property_update(prop, NC_SCENE | NA_EDITED, "rna_Scene_view3d_update"); + RNA_def_property_update(prop, NC_SCENE | NA_EDITED, "rna_Scene_camera_update"); prop = RNA_def_property(srna, "background_set", PROP_POINTER, PROP_NONE); RNA_def_property_pointer_sdna(prop, NULL, "set"); |