summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/shaderapi.c
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2011-08-20 13:51:36 -0700
committerIan Romanick <[email protected]>2011-10-07 16:39:50 -0700
commit010cc547ca8c1fb2107106b0ad0de560780ce9aa (patch)
treec653715e4bac2040927dcdbf2f353c6070984855 /src/mesa/main/shaderapi.c
parent2fae55666e298525fe3b5550aa2a2ebeea437710 (diff)
mesa: Use gl_shader_program::_LinkedShaders instead of VertexProgram
Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/shaderapi.c')
-rw-r--r--src/mesa/main/shaderapi.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
index 9e0ed9c6977..d9559baeff7 100644
--- a/src/mesa/main/shaderapi.c
+++ b/src/mesa/main/shaderapi.c
@@ -808,8 +808,9 @@ print_shader_info(const struct gl_shader_program *shProg)
shProg->Shaders[i]->Name,
shProg->Shaders[i]->SourceChecksum);
}
- if (shProg->VertexProgram)
- printf(" vert prog %u\n", shProg->VertexProgram->Base.Id);
+ if (shProg->_LinkedShaders[MESA_SHADER_VERTEX])
+ printf(" vert prog %u\n",
+ shProg->_LinkedShaders[MESA_SHADER_VERTEX]->Program->Id);
if (shProg->FragmentProgram)
printf(" frag prog %u\n", shProg->FragmentProgram->Base.Id);
if (shProg->GeometryProgram)
@@ -963,7 +964,7 @@ static GLboolean
validate_shader_program(const struct gl_shader_program *shProg,
char *errMsg)
{
- const struct gl_vertex_program *vp = shProg->VertexProgram;
+ const struct gl_shader *vs = shProg->_LinkedShaders[MESA_SHADER_VERTEX];
const struct gl_geometry_program *gp = shProg->GeometryProgram;
const struct gl_fragment_program *fp = shProg->FragmentProgram;
@@ -991,7 +992,7 @@ validate_shader_program(const struct gl_shader_program *shProg,
* Check: any two active samplers in the current program object are of
* different types, but refer to the same texture image unit,
*/
- if (vp && !validate_samplers(&vp->Base, errMsg)) {
+ if (vs && !validate_samplers(vs->Program, errMsg)) {
return GL_FALSE;
}
if (gp && !validate_samplers(&gp->Base, errMsg)) {