summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_triangle.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2004-04-23 14:16:46 +0000
committerBrian Paul <[email protected]>2004-04-23 14:16:46 +0000
commit6d460af6af77a0d5a5b568bcd6094b98e249ba93 (patch)
tree08656028582b357d5c9730c521cc3e1770604c50 /src/mesa/swrast/s_triangle.c
parent384800fe12e368f3489111de4572dbc8846a7dea (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/swrast/s_triangle.c')
-rw-r--r--src/mesa/swrast/s_triangle.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/swrast/s_triangle.c b/src/mesa/swrast/s_triangle.c
index ab262beabc1..00c1a0ace25 100644
--- a/src/mesa/swrast/s_triangle.c
+++ b/src/mesa/swrast/s_triangle.c
@@ -1057,7 +1057,7 @@ _swrast_choose_triangle( GLcontext *ctx )
}
}
- if (ctx->Texture._EnabledCoordUnits || ctx->FragmentProgram.Enabled) {
+ if (ctx->Texture._EnabledCoordUnits || ctx->FragmentProgram._Enabled) {
/* Ugh, we do a _lot_ of tests to pick the best textured tri func */
const struct gl_texture_object *texObj2D;
const struct gl_texture_image *texImg;
@@ -1072,7 +1072,7 @@ _swrast_choose_triangle( GLcontext *ctx )
/* First see if we can use an optimized 2-D texture function */
if (ctx->Texture._EnabledCoordUnits == 1
- && !ctx->FragmentProgram.Enabled
+ && !ctx->FragmentProgram._Enabled
&& ctx->Texture.Unit[0]._ReallyEnabled == TEXTURE_2D_BIT
&& texObj2D->WrapS==GL_REPEAT
&& texObj2D->WrapT==GL_REPEAT