[Bf-blender-cvs] [158397a007e] sculpt-dev: Sculpt IPMask: Ignore inbetween mouse events

Pablo Dobarro noreply at git.blender.org
Fri Feb 26 14:59:02 CET 2021


Commit: 158397a007e6e2d9a9b146fb79e2342a770024f7
Author: Pablo Dobarro
Date:   Fri Feb 26 01:35:30 2021 +0100
Branches: sculpt-dev
https://developer.blender.org/rB158397a007e6e2d9a9b146fb79e2342a770024f7

Sculpt IPMask: Ignore inbetween mouse events

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

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

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

diff --git a/source/blender/editors/sculpt_paint/sculpt_filter_mask.c b/source/blender/editors/sculpt_paint/sculpt_filter_mask.c
index 3277913199b..66ad13521c7 100644
--- a/source/blender/editors/sculpt_paint/sculpt_filter_mask.c
+++ b/source/blender/editors/sculpt_paint/sculpt_filter_mask.c
@@ -608,16 +608,19 @@ static int sculpt_ipmask_filter_modal(bContext *C, wmOperator *op, const wmEvent
     return OPERATOR_FINISHED;
   }
 
-  BKE_sculpt_update_object_for_edit(depsgraph, ob, true, true, false);
+  if (event->type != MOUSEMOVE) {
+    return OPERATOR_RUNNING_MODAL;
+  }
+
 
   const float len = event->x - event->prevclickx;
   const int target_step = len * IPMASK_FILTER_STEP_SENSITIVITY * UI_DPI_FAC;
-
-
   if (target_step == filter_cache->mask_filter_current_step) {
       return OPERATOR_RUNNING_MODAL;
   }
 
+  BKE_sculpt_update_object_for_edit(depsgraph, ob, true, true, false);
+
 
   while(filter_cache->mask_filter_current_step != target_step) {
       int next_step = filter_cache->mask_filter_current_step;



More information about the Bf-blender-cvs mailing list