diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-06-05 13:19:14 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-06-05 13:48:25 +0300 |
commit | 24bd483ee1551e2fb1dadea9fada98045700b5b2 (patch) | |
tree | 819889d748b2df7a8671e81854037ed5709ee6cb /source/blender/editors/sculpt_paint | |
parent | 09f780c1b0fe2671b81b048c1e252dc1ea624abb (diff) |
Object Modes: Flush COW on mode switching
Caused glitch w/ sculpt mode not updating.
Diffstat (limited to 'source/blender/editors/sculpt_paint')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_vertex.c | 4 | ||||
-rw-r--r-- | source/blender/editors/sculpt_paint/sculpt.c | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c index 53b73562322..a6b5ae1af29 100644 --- a/source/blender/editors/sculpt_paint/paint_vertex.c +++ b/source/blender/editors/sculpt_paint/paint_vertex.c @@ -1108,6 +1108,9 @@ static void ed_vwpaintmode_enter_generic( } vertex_paint_init_session(depsgraph, scene, ob); + + /* Flush object mode. */ + DEG_id_tag_update(&ob->id, DEG_TAG_COPY_ON_WRITE); } void ED_object_vpaintmode_enter_ex( @@ -1189,6 +1192,7 @@ static void ed_vwpaintmode_exit_generic( ED_mesh_mirror_topo_table(NULL, NULL, 'e'); } + /* Flush object mode. */ DEG_id_tag_update(&ob->id, DEG_TAG_COPY_ON_WRITE); } diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c index 5dd7f23864c..985857d3f7a 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -5735,6 +5735,9 @@ void ED_object_sculptmode_enter_ex( } // ED_workspace_object_mode_sync_from_object(G.main->wm.first, workspace, ob); + + /* Flush object mode. */ + DEG_id_tag_update(&ob->id, DEG_TAG_COPY_ON_WRITE); } void ED_object_sculptmode_enter(struct bContext *C, ReportList *reports) @@ -5788,6 +5791,7 @@ void ED_object_sculptmode_exit_ex( paint_cursor_delete_textures(); + /* Flush object mode. */ DEG_id_tag_update(&ob->id, DEG_TAG_COPY_ON_WRITE); } |