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>2022-01-10 14:23:44 +0300
committerAntonio Vazquez <blendergit@gmail.com>2022-01-10 14:23:52 +0300
commit934db6a8201afe9b137ff41a3bf3f1da6b32ca02 (patch)
tree5548a3fc9b1f43b0e88cd9176cbc6337714e5e31
parent5aac794b111575bb7b6d32b7ed2af9b7a9993742 (diff)
Fix T94409: GPencil smooth stroke thickness operator weird result
The smooth was not working "smoothly" and any change in the factor produced a weird result.
-rw-r--r--source/blender/editors/gpencil/gpencil_edit.c4
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 2a656ac3aad..e71a56894d0 100644
--- a/source/blender/editors/gpencil/gpencil_edit.c
+++ b/source/blender/editors/gpencil/gpencil_edit.c
@@ -3956,8 +3956,8 @@ static void gpencil_smooth_stroke(bContext *C, wmOperator *op)
}
if (smooth_thickness) {
/* thickness need to repeat process several times */
- for (int r2 = 0; r2 < 20; r2++) {
- BKE_gpencil_stroke_smooth_thickness(gps, i, factor);
+ for (int r2 = 0; r2 < repeat * 2; r2++) {
+ BKE_gpencil_stroke_smooth_thickness(gps, i, 1.0f - factor);
}
}
if (smooth_uv) {