[Bf-blender-cvs] [8e4f3b2bb07] master: Fix T68763: Smooth Brush not working in LookDev or Rendered Mode

Pablo Dobarro noreply at git.blender.org
Tue Aug 27 15:01:19 CEST 2019


Commit: 8e4f3b2bb070a5022200c43866e81b6d5b8d3d1a
Author: Pablo Dobarro
Date:   Sun Aug 25 16:33:52 2019 +0200
Branches: master
https://developer.blender.org/rB8e4f3b2bb070a5022200c43866e81b6d5b8d3d1a

Fix T68763: Smooth Brush not working in LookDev or Rendered Mode

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D5585

===================================================================

M	source/blender/editors/sculpt_paint/sculpt.c

===================================================================

diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 08febfcc470..ea2f38139a4 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -5154,10 +5154,11 @@ static bool sculpt_any_smooth_mode(const Brush *brush, StrokeCache *cache, int s
 static void sculpt_stroke_modifiers_check(const bContext *C, Object *ob, const Brush *brush)
 {
   SculptSession *ss = ob->sculpt;
+  View3D *v3d = CTX_wm_view3d(C);
 
-  if (ss->kb || ss->modifiers_active) {
+  bool need_pmap = sculpt_any_smooth_mode(brush, ss->cache, 0);
+  if (ss->kb || ss->modifiers_active || (!BKE_sculptsession_use_pbvh_draw(ob, v3d) && need_pmap)) {
     Depsgraph *depsgraph = CTX_data_depsgraph_pointer(C);
-    bool need_pmap = sculpt_any_smooth_mode(brush, ss->cache, 0);
     BKE_sculpt_update_object_for_edit(depsgraph, ob, need_pmap, false);
   }
 }



More information about the Bf-blender-cvs mailing list