projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fc5a7ea
)
fix _mesa_get_uniform_location() so it uses the given program handle
author
Brian
<brian@yutani.localnet.net>
Tue, 30 Jan 2007 23:55:03 +0000
(16:55 -0700)
committer
Brian
<brian@yutani.localnet.net>
Tue, 30 Jan 2007 23:55:03 +0000
(16:55 -0700)
src/mesa/shader/shader_api.c
patch
|
blob
|
history
diff --git
a/src/mesa/shader/shader_api.c
b/src/mesa/shader/shader_api.c
index 6bae17a9051a3c469749743eeb4ac0ac49a73c5b..e2fedf7fa647410d5a092043129b159a87c2fb93 100644
(file)
--- a/
src/mesa/shader/shader_api.c
+++ b/
src/mesa/shader/shader_api.c
@@
-741,8
+741,9
@@
_mesa_get_uniformfv(GLcontext *ctx, GLuint program, GLint location,
GLint
_mesa_get_uniform_location(GLcontext *ctx, GLuint program, const GLchar *name)
{
- if (ctx->Shader.CurrentProgram) {
- const struct gl_shader_program *shProg = ctx->Shader.CurrentProgram;
+ struct gl_shader_program *shProg
+ = _mesa_lookup_shader_program(ctx, program);
+ if (shProg) {
GLuint loc;
for (loc = 0; loc < shProg->Uniforms->NumParameters; loc++) {
const struct gl_program_parameter *u