Commit: d731ee4960cf78f7b461be0c8f5ef27c098da265
Author: Campbell Barton
Date:   Tue Mar 19 13:07:48 2019 +1100
Branches: master
https://developer.blender.org/rBd731ee4960cf78f7b461be0c8f5ef27c098da265

Fix T61368: Brush texture preview ignores rotation

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

M       source/blender/windowmanager/intern/wm_operators.c

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

diff --git a/source/blender/windowmanager/intern/wm_operators.c 
b/source/blender/windowmanager/intern/wm_operators.c
index ff3d1601dde..ac7d496ea35 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -2062,11 +2062,6 @@ static void radial_control_paint_tex(RadialControl *rc, 
float radius, float alph
                GLint swizzleMask[] = {GL_ZERO, GL_ZERO, GL_ZERO, GL_RED};
                glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_RGBA, 
swizzleMask);
 
-               immBindBuiltinProgram(GPU_SHADER_2D_IMAGE_MASK_UNIFORM_COLOR);
-
-               immUniformColor3fvAlpha(col, alpha);
-               immUniform1i("image", 0);
-
                /* set up rotation if available */
                if (rc->rot_prop) {
                        rot = RNA_property_float_get(&rc->rot_ptr, 
rc->rot_prop);
@@ -2074,6 +2069,11 @@ static void radial_control_paint_tex(RadialControl *rc, 
float radius, float alph
                        GPU_matrix_rotate_2d(RAD2DEGF(rot));
                }
 
+               immBindBuiltinProgram(GPU_SHADER_2D_IMAGE_MASK_UNIFORM_COLOR);
+
+               immUniformColor3fvAlpha(col, alpha);
+               immUniform1i("image", 0);
+
                /* draw textured quad */
                immBegin(GPU_PRIM_TRI_FAN, 4);

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to