mesa: Validate sampler settings using uniform storage
authorIan Romanick <ian.d.romanick@intel.com>
Mon, 14 Nov 2011 20:11:46 +0000 (12:11 -0800)
committerIan Romanick <ian.d.romanick@intel.com>
Wed, 11 Jan 2012 20:51:24 +0000 (12:51 -0800)
commit195ee502c3196607e3a74075aefade9770a08a67
treef1471a5acefee33601908b051791e02418a5ddf7
parentb527dd65c830a2b008816cf390d5be906e29bb23
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 <ian.d.romanick@intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/shaderapi.c
src/mesa/main/uniform_query.cpp
src/mesa/main/uniforms.h