[Bf-blender-cvs] [a36a44bb811] master: Fix paint curve not drawing selection colors properly

Brecht Van Lommel noreply at git.blender.org
Tue Jul 16 20:33:26 CEST 2019


Commit: a36a44bb811d8dbe39dfaf79e21c509b3134ec66
Author: Brecht Van Lommel
Date:   Tue Jul 16 20:31:23 2019 +0200
Branches: master
https://developer.blender.org/rBa36a44bb811d8dbe39dfaf79e21c509b3134ec66

Fix paint curve not drawing selection colors properly

This code is not guaranteed to run with any specific space theme, so pass
it explicitly.

===================================================================

M	source/blender/editors/sculpt_paint/paint_cursor.c

===================================================================

diff --git a/source/blender/editors/sculpt_paint/paint_cursor.c b/source/blender/editors/sculpt_paint/paint_cursor.c
index 65e24cecf82..ac74afce79e 100644
--- a/source/blender/editors/sculpt_paint/paint_cursor.c
+++ b/source/blender/editors/sculpt_paint/paint_cursor.c
@@ -964,9 +964,9 @@ static void paint_draw_curve_cursor(Brush *brush, ViewContext *vc)
     immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
 
     float selec_col[4], handle_col[4], pivot_col[4];
-    UI_GetThemeColor4fv(TH_VERTEX_SELECT, selec_col);
-    UI_GetThemeColor4fv(TH_PAINT_CURVE_HANDLE, handle_col);
-    UI_GetThemeColor4fv(TH_PAINT_CURVE_PIVOT, pivot_col);
+    UI_GetThemeColorType4fv(TH_VERTEX_SELECT, SPACE_VIEW3D, selec_col);
+    UI_GetThemeColorType4fv(TH_PAINT_CURVE_HANDLE, SPACE_VIEW3D, handle_col);
+    UI_GetThemeColorType4fv(TH_PAINT_CURVE_PIVOT, SPACE_VIEW3D, pivot_col);
 
     for (i = 0; i < pc->tot_points - 1; i++, cp++) {
       int j;



More information about the Bf-blender-cvs mailing list