diff options
author | Antonioya <blendergit@gmail.com> | 2019-03-30 12:43:52 +0300 |
---|---|---|
committer | Antonioya <blendergit@gmail.com> | 2019-03-30 12:43:52 +0300 |
commit | 127ad4fa4a3f7f1037c654288acbe32d4267fe9a (patch) | |
tree | f1c52ae4e0b93951d12b95eeba5f974b88a09474 /source/blender/editors/gpencil | |
parent | de0dab66ff896992251763d6e799cc682ff03543 (diff) |
GPencil: Improve soft eraser for low pressure strokes
For very thin strokes with low pressure, the low limit value was too high.
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_paint.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c index d9a58ddc5a6..4250b95de6d 100644 --- a/source/blender/editors/gpencil/gpencil_paint.c +++ b/source/blender/editors/gpencil/gpencil_paint.c @@ -1494,19 +1494,15 @@ static void gp_stroke_eraser_dostroke(tGPsdata *p, } } else { - /* Pressure threshold at which stroke should be culled: Calculated as pressure value - * below which we would have invisible strokes - */ - const float cull_thresh = (gps->thickness) ? 1.0f / ((float)gps->thickness) : 1.0f; + /* Pressure threshold at which stroke should be culled */ + const float cull_thresh = 0.005f; /* Amount to decrease the pressure of each point with each stroke */ - // TODO: Fetch from toolsettings, or compute based on thickness instead? const float strength = 0.1f; /* Perform culling? */ bool do_cull = false; - /* Clear Tags * * Note: It's better this way, as we are sure that |