From c2938ad4d91b914065dde2cb9254b4ea0e1217f3 Mon Sep 17 00:00:00 2001 From: Yuxuan Shui Date: Sat, 7 Mar 2020 17:31:46 +0000 Subject: [PATCH] gl_common: no need to get "opacity" uniform for dummy shader Prevent a useless error message from glGetUniformLocationChecked, as "opacity" is not used by the dummy shader, we will fail to get its location. Signed-off-by: Yuxuan Shui --- src/backend/gl/gl_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/gl/gl_common.c b/src/backend/gl/gl_common.c index 2ff595e..3029b0c 100644 --- a/src/backend/gl/gl_common.c +++ b/src/backend/gl/gl_common.c @@ -1092,7 +1092,7 @@ void *gl_create_blur_context(backend_t *base, enum blur_method method, void *arg // the single pass case auto pass = &ctx->blur_shader[1]; pass->prog = gl_create_program_from_str(vertex_shader, dummy_frag); - pass->unifm_opacity = glGetUniformLocationChecked(pass->prog, "opacity"); + pass->unifm_opacity = -1; pass->orig_loc = glGetUniformLocationChecked(pass->prog, "orig"); pass->texorig_loc = glGetUniformLocationChecked(pass->prog, "texorig"); ctx->npasses = 2;