Commit: 4e8de29546e7bd4b46608106c44fbd20d6e088c1
Author: Antonio Vazquez
Date: Sun Nov 17 19:47:13 2019 +0100
Branches: greasepencil-object
https://developer.blender.org/rB4e8de29546e7bd4b46608106c44fbd20d6e088c1
GPencil: Fix Fill tint problems
When the stroke was already tinted, the color changes with the first click. Now
the color is mixed.
===================================================================
M source/blender/editors/gpencil/gpencil_vertex_paint.c
===================================================================
diff --git a/source/blender/editors/gpencil/gpencil_vertex_paint.c
b/source/blender/editors/gpencil/gpencil_vertex_paint.c
index dceffad345e..1778ac16870 100644
--- a/source/blender/editors/gpencil/gpencil_vertex_paint.c
+++ b/source/blender/editors/gpencil/gpencil_vertex_paint.c
@@ -461,7 +461,12 @@ static bool brush_tint_apply(tGP_BrushVertexpaintData *gso,
/* Apply color to Fill area (all with same color and factor). */
if (GPENCIL_TINT_VERTEX_COLOR_FILL(brush)) {
CLAMP(alpha_fill, 0.0f, 1.0f);
- copy_v3_v3(gps->mix_color_fill, brush->rgb);
+ if (equals_v3v3(gps->mix_color_fill, brush->rgb)) {
+ copy_v3_v3(gps->mix_color_fill, brush->rgb);
+ }
+ else {
+ interp_v3_v3v3(gps->mix_color_fill, gps->mix_color_fill, brush->rgb,
inf_fill);
+ }
gps->mix_color_fill[3] = alpha_fill;
}
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs