[Bf-blender-cvs] [cc72dd73760] blender-v2.93-release: Fix T87596: Pose brush not using automasking options

Pablo Dobarro noreply at git.blender.org
Tue Apr 27 21:39:18 CEST 2021


Commit: cc72dd73760ab41442e4ce7c81bea8697207d27d
Author: Pablo Dobarro
Date:   Sun Apr 18 18:33:56 2021 +0200
Branches: blender-v2.93-release
https://developer.blender.org/rBcc72dd73760ab41442e4ce7c81bea8697207d27d

Fix T87596: Pose brush not using automasking options

Automasking cache factors were missing in the pose brush deform function.

Reviewed By: JacquesLucke

Maniphest Tasks: T87596

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

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

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

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

diff --git a/source/blender/editors/sculpt_paint/sculpt_pose.c b/source/blender/editors/sculpt_paint/sculpt_pose.c
index 4d2a1bf13dc..587ce346428 100644
--- a/source/blender/editors/sculpt_paint/sculpt_pose.c
+++ b/source/blender/editors/sculpt_paint/sculpt_pose.c
@@ -197,8 +197,9 @@ static void do_pose_brush_task_cb_ex(void *__restrict userdata,
       mul_v3_fl(disp, segments[ik].weights[vd.index]);
 
       /* Apply the vertex mask to the displacement. */
-      float mask = vd.mask ? *vd.mask : 0.0f;
-      mul_v3_fl(disp, 1.0f - mask);
+      const float mask = vd.mask ? 1.0f - *vd.mask : 1.0f;
+      const float automask = SCULPT_automasking_factor_get(ss->cache->automasking, ss, vd.index);
+      mul_v3_fl(disp, mask * automask);
 
       /* Accumulate the displacement. */
       add_v3_v3(total_disp, disp);



More information about the Bf-blender-cvs mailing list