diff options
author | Antonioya <blendergit@gmail.com> | 2019-08-15 18:49:55 +0300 |
---|---|---|
committer | Antonioya <blendergit@gmail.com> | 2019-08-17 13:51:05 +0300 |
commit | 0e1d4dec7a7d50867c97179299775d31ac30938e (patch) | |
tree | 1c12c30c6fac5e840582b5c2f539b176eb1c8fc8 /source/blender/editors | |
parent | a477c2e0e07943553e319d430dce0df1015d790b (diff) |
Fix T68722: Improve Smooth algorithm for Thickness and Strength
Now the GPencil smooth algorithm uses a average value instead to use only two points and the interpolated value.
Differential Revision: https://developer.blender.org/D5489
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_edit.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c index f509be9312a..878f7a1995b 100644 --- a/source/blender/editors/gpencil/gpencil_edit.c +++ b/source/blender/editors/gpencil/gpencil_edit.c @@ -3546,7 +3546,7 @@ static void gp_smooth_stroke(bContext *C, wmOperator *op) } if (smooth_thickness) { /* thickness need to repeat process several times */ - for (int r2 = 0; r2 < r * 10; r2++) { + for (int r2 = 0; r2 < r * 20; r2++) { BKE_gpencil_smooth_stroke_thickness(gps, i, factor); } } @@ -4302,7 +4302,7 @@ void GPENCIL_OT_stroke_smooth(wmOperatorType *ot) ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; /* properties */ - prop = RNA_def_int(ot->srna, "repeat", 1, 1, 10, "Repeat", "", 1, 5); + prop = RNA_def_int(ot->srna, "repeat", 1, 1, 50, "Repeat", "", 1, 20); RNA_def_property_flag(prop, PROP_SKIP_SAVE); RNA_def_float(ot->srna, "factor", 0.5f, 0.0f, 2.0f, "Factor", "", 0.0f, 2.0f); |