summaryrefslogtreecommitdiffstats
path: root/src/glsl/ir_uniform.h
diff options
context:
space:
mode:
authorTapani Pälli <[email protected]>2014-04-08 08:45:36 +0300
committerTapani Pälli <[email protected]>2014-06-16 06:49:59 +0300
commiteca9d160483fa04caa8c8aeb527d7e42016dfeb2 (patch)
tree98ecda1da7e55b352c9a45a8453188d2f20e3233 /src/glsl/ir_uniform.h
parentdadc3d04f034327b4afeeadf9a860e1b620fab37 (diff)
glsl/linker: initialize explicit uniform locations
Patch initializes the UniformRemapTable for explicit locations. This needs to happen before optimizations to make sure all inactive uniforms get their explicit locations correctly. v2: fix initialization bug, introduce define for inactive uniforms (Ian) Signed-off-by: Tapani Pälli <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/glsl/ir_uniform.h')
-rw-r--r--src/glsl/ir_uniform.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/glsl/ir_uniform.h b/src/glsl/ir_uniform.h
index 4829eb70292..2f73528257e 100644
--- a/src/glsl/ir_uniform.h
+++ b/src/glsl/ir_uniform.h
@@ -32,6 +32,11 @@
#include "program/prog_parameter.h" /* For union gl_constant_value. */
+/**
+ * Used by GL_ARB_explicit_uniform_location extension code in the linker
+ * and glUniform* functions to identify inactive explicit uniform locations.
+ */
+#define INACTIVE_UNIFORM_EXPLICIT_LOCATION ((gl_uniform_storage *) -1)
#ifdef __cplusplus
extern "C" {