[Bf-blender-cvs] [b9e46966418] master: Sculpt: Show paint brush cursor in all tools

Pablo Dobarro noreply at git.blender.org
Thu Oct 15 19:04:31 CEST 2020


Commit: b9e469664188ac675f3743e8d3938f34c996957e
Author: Pablo Dobarro
Date:   Thu Oct 1 01:52:40 2020 +0200
Branches: master
https://developer.blender.org/rBb9e469664188ac675f3743e8d3938f34c996957e

Sculpt: Show paint brush cursor in all tools

This patch enables the paint brush cursor with all tools in sculpt mode,
even with the ones that are not brushes. The motivations for this change
are:
- The filters are using the position of the active vertex for certain
features without any visualization of what the active vertex is.

- You can call operators like mask expand (which depends on the brush
cursor position and active vertex) with a non brush tool enabled.

- Having the cursor in the rest of the tools allows to have a scene
scale representation of the radius and a direct control of radius and
strength (using the current brush shortcuts), which will allow to make
features more intuitive without relying on modifying values in the
topbar. For example, the brush radius can be used to control the depth
of the cut in the trimming tools or the size of the sphere in the
sphere mesh filter

Reviewed By: #user_interface, dbystedt, pablovazquez

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

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

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 6e99edcf682..8a9d1bba92c 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -8197,7 +8197,7 @@ void ED_object_sculptmode_enter_ex(Main *bmain,
   Paint *paint = BKE_paint_get_active_from_paintmode(scene, PAINT_MODE_SCULPT);
   BKE_paint_init(bmain, scene, PAINT_MODE_SCULPT, PAINT_CURSOR_SCULPT);
 
-  paint_cursor_start(paint, SCULPT_poll_view3d);
+  paint_cursor_start(paint, SCULPT_mode_poll_view3d);
 
   /* Check dynamic-topology flag; re-enter dynamic-topology mode when changing modes,
    * As long as no data was added that is not supported. */



More information about the Bf-blender-cvs mailing list