[Bf-blender-cvs] [dc3fb012e74] master: Fix T82297: Brush alpha not affecting smear tools strength
Pablo Dobarro
noreply at git.blender.org
Tue Nov 3 23:55:56 CET 2020
Commit: dc3fb012e749e887e8439df7c4737295c6c0234d
Author: Pablo Dobarro
Date: Mon Nov 2 20:27:42 2020 +0100
Branches: master
https://developer.blender.org/rBdc3fb012e749e887e8439df7c4737295c6c0234d
Fix T82297: Brush alpha not affecting smear tools strength
The strength of this brush needs to take alpha into account
Reviewed By: sergey
Maniphest Tasks: T82297
Differential Revision: https://developer.blender.org/D9419
===================================================================
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 754204201f4..d4bd15badac 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -2347,7 +2347,7 @@ static float brush_strength(const Sculpt *sd,
final_pressure = pressure * pressure;
return final_pressure * overlap * feather;
case SCULPT_TOOL_SMEAR:
- return pressure * overlap * feather;
+ return alpha * pressure * overlap * feather;
case SCULPT_TOOL_CLAY_STRIPS:
/* Clay Strips needs less strength to compensate the curve. */
final_pressure = powf(pressure, 1.5f);
More information about the Bf-blender-cvs
mailing list