summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/uniforms.h
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2011-11-14 12:11:46 -0800
committerIan Romanick <[email protected]>2012-01-11 12:51:24 -0800
commit195ee502c3196607e3a74075aefade9770a08a67 (patch)
treef1471a5acefee33601908b051791e02418a5ddf7 /src/mesa/main/uniforms.h
parentb527dd65c830a2b008816cf390d5be906e29bb23 (diff)
mesa: Validate sampler settings using uniform storage
Rather than looking at the settings in individual assembly programs, look at the settings in the top-level uniform values. The old code was flawed because examining each shader stage in isolation could allow inconsitent usage across stages (e.g., bind unit 0 to a sampler2D in the vertex shader and sampler1DShadow in the fragment shader). Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/uniforms.h')
-rw-r--r--src/mesa/main/uniforms.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/main/uniforms.h b/src/mesa/main/uniforms.h
index 123d7b95423..f796f82766e 100644
--- a/src/mesa/main/uniforms.h
+++ b/src/mesa/main/uniforms.h
@@ -214,6 +214,9 @@ _mesa_propagate_uniforms_to_driver_storage(struct gl_uniform_storage *uni,
extern void
_mesa_update_shader_textures_used(struct gl_program *prog);
+extern bool
+_mesa_sampler_uniforms_are_valid(const struct gl_shader_program *shProg,
+ char *errMsg, size_t errMsgLength);
extern void
_mesa_init_shader_uniform_dispatch(struct _glapi_table *exec);