aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/main/uniforms.h
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2010-09-28 16:06:35 -0700
committerEric Anholt <[email protected]>2010-09-28 16:26:58 -0700
commitdaacaac3c8b91c87ab2cfc2d9f821474552b8181 (patch)
tree150b413e97591aa4166182dcc66f3b7827e6c9b9 /src/mesa/main/uniforms.h
parent9ac910cfcddf1b6e7c520261371e78fc9bcbddcf (diff)
mesa: Move the list of builtin uniform info from ir_to_mesa to shared code.
I'm still not pleased with how builtin uniforms are handled, but as long as we're relying on the prog_statevar stuff this seems about as good as it'll get.
Diffstat (limited to 'src/mesa/main/uniforms.h')
-rw-r--r--src/mesa/main/uniforms.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/mesa/main/uniforms.h b/src/mesa/main/uniforms.h
index f823c614447..ac2cf30d97e 100644
--- a/src/mesa/main/uniforms.h
+++ b/src/mesa/main/uniforms.h
@@ -26,6 +26,7 @@
#define UNIFORMS_H
#include "glheader.h"
+#include "program/prog_parameter.h"
struct gl_program;
struct _glapi_table;
@@ -172,4 +173,18 @@ _mesa_update_shader_textures_used(struct gl_program *prog);
extern void
_mesa_init_shader_uniform_dispatch(struct _glapi_table *exec);
+struct gl_builtin_uniform_element {
+ const char *field;
+ int tokens[STATE_LENGTH];
+ int swizzle;
+};
+
+struct gl_builtin_uniform_desc {
+ const char *name;
+ struct gl_builtin_uniform_element *elements;
+ unsigned int num_elements;
+};
+
+extern const struct gl_builtin_uniform_desc _mesa_builtin_uniform_desc[];
+
#endif /* UNIFORMS_H */