Commit: 89cdf4f75dd0f2d7cfd993cff7797371b73627d0 Author: Pablo Dobarro Date: Wed Sep 2 22:33:05 2020 +0200 Branches: master https://developer.blender.org/rB89cdf4f75dd0f2d7cfd993cff7797371b73627d0
Fix Cloth Snake Hook brush not using pressure The Snake Hook deformation mode was using the same strength as grab (not supporting pressure), but this deformation mode supports pressure. Reviewed By: sergey Differential Revision: https://developer.blender.org/D8724 =================================================================== 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 7cb4f74282b..1078e97e7cf 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -2273,10 +2273,13 @@ static float brush_strength(const Sculpt *sd, case SCULPT_TOOL_DISPLACEMENT_ERASER: return alpha * pressure * overlap * feather; case SCULPT_TOOL_CLOTH: - if (ELEM(brush->cloth_deform_type, BRUSH_CLOTH_DEFORM_GRAB, BRUSH_CLOTH_DEFORM_SNAKE_HOOK)) { + if (brush->cloth_deform_type == BRUSH_CLOTH_DEFORM_GRAB) { /* Grab deform uses the same falloff as a regular grab brush. */ return root_alpha * feather; } + else if (brush->cloth_deform_type == BRUSH_CLOTH_DEFORM_SNAKE_HOOK) { + return root_alpha * feather * pressure * overlap; + } else if (brush->cloth_deform_type == BRUSH_CLOTH_DEFORM_EXPAND) { /* Expand is more sensible to strength as it keeps expanding the cloth when sculpting over * the same vertices. */ _______________________________________________ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs