diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-10-20 02:45:59 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-10-20 03:16:43 +0300 |
commit | b280699078eee23bd8eb572668d6f0d8972d879a (patch) | |
tree | 8b6b8461938e71914d28e707137a8960f8a2d03c /source/blender/editors/sculpt_paint/sculpt.c | |
parent | ef9269bd62f31e39d39cc59cd34354b53eae6661 (diff) |
Cleanup: use elem macros
Diffstat (limited to 'source/blender/editors/sculpt_paint/sculpt.c')
-rw-r--r-- | source/blender/editors/sculpt_paint/sculpt.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c index 95be866adf1..1330beb917b 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -1046,7 +1046,7 @@ int SCULPT_nearest_vertex_get( bool SCULPT_is_symmetry_iteration_valid(char i, char symm) { - return i == 0 || (symm & i && (symm != 5 || i != 3) && (symm != 6 || (i != 3 && i != 5))); + return i == 0 || (symm & i && (symm != 5 || i != 3) && (symm != 6 || (!ELEM(i, 3, 5)))); } /* Checks if a vertex is inside the brush radius from any of its mirrored axis. */ @@ -7695,8 +7695,7 @@ static void sculpt_restore_mesh(Sculpt *sd, Object *ob) /* Restore the mesh before continuing with anchored stroke. */ if ((brush->flag & BRUSH_ANCHORED) || - ((brush->sculpt_tool == SCULPT_TOOL_GRAB || - brush->sculpt_tool == SCULPT_TOOL_ELASTIC_DEFORM) && + ((ELEM(brush->sculpt_tool, SCULPT_TOOL_GRAB, SCULPT_TOOL_ELASTIC_DEFORM)) && BKE_brush_use_size_pressure(brush)) || (brush->flag & BRUSH_DRAG_DOT)) { |