summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/uniforms.h
diff options
context:
space:
mode:
authorIan Romanick <ian.d.romanick@intel.com>2011-10-18 16:01:49 -0700
committerIan Romanick <ian.d.romanick@intel.com>2011-11-07 13:33:16 -0800
commit719909698c67c287a393d2380278e7b7495ae018 (patch)
tree1a49879205ab93ea2d67db62cd8282b60302bdd7 /src/mesa/main/uniforms.h
parent143d20c16a33e2f08e834b28c23dbea772591ef9 (diff)
downloadexternal_mesa3d-719909698c67c287a393d2380278e7b7495ae018.zip
external_mesa3d-719909698c67c287a393d2380278e7b7495ae018.tar.gz
external_mesa3d-719909698c67c287a393d2380278e7b7495ae018.tar.bz2
mesa: Rewrite the way uniforms are tracked and handled
Switch all of the code in ir_to_mesa, st_glsl_to_tgsi, glUniform*, glGetUniform, glGetUniformLocation, and glGetActiveUniforms to use the gl_uniform_storage structures in the gl_shader_program. A couple of notes: * Like most rewrite-the-world patches, this should be reviewed by applying the patch and examining the modified functions. * This leaves a lot of dead code around in linker.cpp and uniform_query.cpp. This will be deleted in the next patches. v2: Update the comment block (previously a FINISHME) in _mesa_uniform about generating GL_INVALID_VALUE when an out-of-range sampler index is specified. Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Tested-by: Tom Stellard <thomas.stellard@amd.com>
Diffstat (limited to 'src/mesa/main/uniforms.h')
-rw-r--r--src/mesa/main/uniforms.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesa/main/uniforms.h b/src/mesa/main/uniforms.h
index b90f64b..6b102ec 100644
--- a/src/mesa/main/uniforms.h
+++ b/src/mesa/main/uniforms.h
@@ -27,6 +27,7 @@
#include "glheader.h"
#include "program/prog_parameter.h"
+#include "../glsl/glsl_types.h"
#include "../glsl/ir_uniform.h"
struct gl_program;
@@ -187,7 +188,8 @@ _mesa_uniform_matrix(struct gl_context *ctx, struct gl_shader_program *shProg,
void
_mesa_get_uniform(struct gl_context *ctx, GLuint program, GLint location,
- GLsizei bufSize, GLenum returnType, GLvoid *paramsOut);
+ GLsizei bufSize, enum glsl_base_type returnType,
+ GLvoid *paramsOut);
extern void
_mesa_uniform_attach_driver_storage(struct gl_uniform_storage *,