From 517401af07ea17a7e88659e6ba95a0628ff826b3 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 6 Nov 2008 15:04:11 -0700 Subject: mesa: update the shader programs->TexturesUsed array at link time If an application never calls glUniform() to set sampler variable values they'll remain 0 (the default value/unit). Now call _mesa_update_shader_textures_used() at link time in case glUniform() is never called. program->TextureUsed[] will then be correct for state validation. --- src/mesa/shader/shader_api.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/mesa/shader/shader_api.h') diff --git a/src/mesa/shader/shader_api.h b/src/mesa/shader/shader_api.h index e7f1266915..ec1996ee98 100644 --- a/src/mesa/shader/shader_api.h +++ b/src/mesa/shader/shader_api.h @@ -79,6 +79,10 @@ extern struct gl_shader * _mesa_lookup_shader(GLcontext *ctx, GLuint name); +extern void +_mesa_update_shader_textures_used(struct gl_program *prog); + + extern void _mesa_use_program(GLcontext *ctx, GLuint program); -- cgit v1.2.3