GPU: Rename GPU_shader_get_uniform to GPU_shader_get_uniform_ensure
[blender.git] / source / blender / editors / space_image / image_draw.c
index a46767495dda8102d1d215f831c65a6de36c34b9..21b917b607dc243444ed642e449290f1769c9df4 100644 (file)
@@ -434,7 +434,7 @@ static void sima_draw_zbuf_pixels(float x1, float y1, int rectx, int recty, int
        }
 
        IMMDrawPixelsTexState state = immDrawPixelsTexSetup(GPU_SHADER_2D_IMAGE_SHUFFLE_COLOR);
-       GPU_shader_uniform_vector(state.shader, GPU_shader_get_uniform(state.shader, "shuffle"), 4, 1, red);
+       GPU_shader_uniform_vector(state.shader, GPU_shader_get_uniform_ensure(state.shader, "shuffle"), 4, 1, red);
 
        immDrawPixelsTex(&state, x1, y1, rectx, recty, GL_RED, GL_INT, GL_NEAREST, recti, zoomx, zoomy, NULL);
 
@@ -472,7 +472,7 @@ static void sima_draw_zbuffloat_pixels(Scene *scene, float x1, float y1, int rec
        }
 
        IMMDrawPixelsTexState state = immDrawPixelsTexSetup(GPU_SHADER_2D_IMAGE_SHUFFLE_COLOR);
-       GPU_shader_uniform_vector(state.shader, GPU_shader_get_uniform(state.shader, "shuffle"), 4, 1, red);
+       GPU_shader_uniform_vector(state.shader, GPU_shader_get_uniform_ensure(state.shader, "shuffle"), 4, 1, red);
 
        immDrawPixelsTex(&state, x1, y1, rectx, recty, GL_RED, GL_FLOAT, GL_NEAREST, rectf, zoomx, zoomy, NULL);
 
@@ -531,7 +531,7 @@ static void draw_image_buffer(const bContext *C, SpaceImage *sima, ARegion *ar,
                                shuffle[3] = 1.0f;
 
                        IMMDrawPixelsTexState state = immDrawPixelsTexSetup(GPU_SHADER_2D_IMAGE_SHUFFLE_COLOR);
-                       GPU_shader_uniform_vector(state.shader, GPU_shader_get_uniform(state.shader, "shuffle"), 4, 1, shuffle);
+                       GPU_shader_uniform_vector(state.shader, GPU_shader_get_uniform_ensure(state.shader, "shuffle"), 4, 1, shuffle);
 
                        IMB_colormanagement_display_settings_from_ctx(C, &view_settings, &display_settings);
                        display_buffer = IMB_display_buffer_acquire(ibuf, view_settings, display_settings, &cache_handle);