Fix #112285: Sculpt Mode: Mask brush smoothing is broken #112292
@ -4299,12 +4299,14 @@ static void smooth_brush_toggle_on(const bContext *C, Paint *paint, StrokeCache
|
||||
if (cur_brush->sculpt_tool == SCULPT_TOOL_MASK) {
|
||||
cache->saved_mask_brush_tool = cur_brush->mask_tool;
|
||||
cur_brush->mask_tool = BRUSH_MASK_SMOOTH;
|
||||
return;
|
||||
}
|
||||
else if (ELEM(cur_brush->sculpt_tool,
|
||||
SCULPT_TOOL_SLIDE_RELAX,
|
||||
SCULPT_TOOL_DRAW_FACE_SETS,
|
||||
SCULPT_TOOL_PAINT,
|
||||
SCULPT_TOOL_SMEAR))
|
||||
|
||||
lichtwerk marked this conversation as resolved
Outdated
|
||||
if (ELEM(cur_brush->sculpt_tool,
|
||||
SCULPT_TOOL_SLIDE_RELAX,
|
||||
SCULPT_TOOL_DRAW_FACE_SETS,
|
||||
SCULPT_TOOL_PAINT,
|
||||
SCULPT_TOOL_SMEAR))
|
||||
{
|
||||
/* Do nothing, this tool has its own smooth mode. */
|
||||
return;
|
||||
@ -4335,14 +4337,17 @@ static void smooth_brush_toggle_off(const bContext *C, Paint *paint, StrokeCache
|
||||
|
||||
if (brush->sculpt_tool == SCULPT_TOOL_MASK) {
|
||||
brush->mask_tool = cache->saved_mask_brush_tool;
|
||||
return;
|
||||
}
|
||||
else if (ELEM(brush->sculpt_tool,
|
||||
SCULPT_TOOL_SLIDE_RELAX,
|
||||
SCULPT_TOOL_DRAW_FACE_SETS,
|
||||
SCULPT_TOOL_PAINT,
|
||||
SCULPT_TOOL_SMEAR))
|
||||
|
||||
if (ELEM(brush->sculpt_tool,
|
||||
SCULPT_TOOL_SLIDE_RELAX,
|
||||
SCULPT_TOOL_DRAW_FACE_SETS,
|
||||
SCULPT_TOOL_PAINT,
|
||||
SCULPT_TOOL_SMEAR))
|
||||
{
|
||||
/* Do nothing. */
|
||||
return;
|
||||
}
|
||||
|
||||
/* If saved_active_brush_name is not set, brush was not switched/affected in
|
||||
|
Loading…
Reference in New Issue
Block a user
Looks like there's an else after return that can be cleaned up here
Thx spotting this!