Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonio Vazquez <blendergit@gmail.com>2021-09-03 16:24:01 +0300
committerAntonio Vazquez <blendergit@gmail.com>2021-09-03 16:24:13 +0300
commitae334532cffb2dd9074454b9a7ba095430f18735 (patch)
treea417085b903fb1849b14a70946225a08a479f786 /source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c
parentf9ccd26b037d43f2490d1f0263e45e775d30473d (diff)
GPencil: Smooth thickness when joining strokes
When joining two strokes in paint mode using the auto merge option, the join was very hard if the thickness was too different. This patch adds a smooth to the join in order to get better transition. Also fixed the problem to join existing strokes very far from actual stroke. Some cleanup and rename of old code is included in order to make code more readable. Reviewed By: pepeland Differential Revision: https://developer.blender.org/D12362
Diffstat (limited to 'source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c')
-rw-r--r--source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c b/source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c
index 4142a1c02dc..b00db1ba2d2 100644
--- a/source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c
+++ b/source/blender/gpencil_modifiers/intern/MOD_gpencilsmooth.c
@@ -132,7 +132,7 @@ static void deformStroke(GpencilModifierData *md,
const float val = mmd->factor * weight;
/* perform smoothing */
if (mmd->flag & GP_SMOOTH_MOD_LOCATION) {
- BKE_gpencil_stroke_smooth(gps, i, val);
+ BKE_gpencil_stroke_smooth_point(gps, i, val);
}
if (mmd->flag & GP_SMOOTH_MOD_STRENGTH) {
BKE_gpencil_stroke_smooth_strength(gps, i, val);