diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2020-06-15 12:48:56 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2020-06-15 12:49:08 +0300 |
commit | 76ebc608af7a89d2e9919d67ec6b639d47f70c1a (patch) | |
tree | a35a0216d06eb8bab79e4b2ed0e50a12fd44df20 /source/blender/editors/gpencil/gpencil_sculpt_paint.c | |
parent | 0c384362272637a3e55b480ac03527a1d1df7a90 (diff) |
Fix T77871: GPencil masked points fails with previous point
If selected a point for masking, the previous point that is part of the same segment was included.
This bug was in Sculpt and Vertex paint modes because the code was very similar.
Diffstat (limited to 'source/blender/editors/gpencil/gpencil_sculpt_paint.c')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_sculpt_paint.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/editors/gpencil/gpencil_sculpt_paint.c b/source/blender/editors/gpencil/gpencil_sculpt_paint.c index f7f3b128351..6bd945160a6 100644 --- a/source/blender/editors/gpencil/gpencil_sculpt_paint.c +++ b/source/blender/editors/gpencil/gpencil_sculpt_paint.c @@ -1506,6 +1506,11 @@ static bool gpsculpt_brush_do_stroke(tGP_BrushEditData *gso, continue; } pt_active = (pt->runtime.pt_orig) ? pt->runtime.pt_orig : pt; + /* If masked and the point is not selected, skip it. */ + if ((GPENCIL_ANY_SCULPT_MASK(gso->mask)) && + ((pt_active->flag & GP_SPOINT_SELECT) == 0)) { + continue; + } index = (pt->runtime.pt_orig) ? pt->runtime.idx_orig : i; if ((pt_active != NULL) && (index < gps_active->totpoints)) { rot_eval = gpsculpt_rotation_eval_get(gso, gps, pt, i); |