diff options
author | Brian Paul <[email protected]> | 2004-04-23 14:16:46 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2004-04-23 14:16:46 +0000 |
commit | 6d460af6af77a0d5a5b568bcd6094b98e249ba93 (patch) | |
tree | 08656028582b357d5c9730c521cc3e1770604c50 /src/mesa/main/texstate.c | |
parent | 384800fe12e368f3489111de4572dbc8846a7dea (diff) |
Added ctx->Vertex/FragmentProgram._Enable flags. Set when vertex/fragment
program is enabled AND the currently bound program is valid.
Check _Enable instead of Enable to prevent things from blowing up
when someone calls glEnable(GL_VERTEX_PROGRAM_ARB) without actually
defining a program.
Diffstat (limited to 'src/mesa/main/texstate.c')
-rw-r--r-- | src/mesa/main/texstate.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c index 38dd4442a72..54835c9dda2 100644 --- a/src/mesa/main/texstate.c +++ b/src/mesa/main/texstate.c @@ -2935,7 +2935,7 @@ update_texture_state( GLcontext *ctx ) texUnit->_GenFlags = 0; /* Get the bitmask of texture enables */ - if (ctx->FragmentProgram.Enabled && ctx->FragmentProgram.Current) { + if (ctx->FragmentProgram._Enabled) { enableBits = ctx->FragmentProgram.Current->TexturesUsed[unit]; } else { @@ -3099,7 +3099,7 @@ update_texture_state( GLcontext *ctx ) /* Fragment programs may need texture coordinates but not the * corresponding texture images. */ - if (ctx->FragmentProgram.Enabled && ctx->FragmentProgram.Current) { + if (ctx->FragmentProgram._Enabled) { ctx->Texture._EnabledCoordUnits |= (ctx->FragmentProgram.Current->InputsRead >> FRAG_ATTRIB_TEX0); } |