From d475730357ff1595470fbe9856b2c88ad0a771ca Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 20 Oct 2000 19:54:49 +0000 Subject: Changes for multitexture > 3, code clean-ups. Added GLboolean ctx->Texture.MultiTextureEnabled to determine when multitexture is enabled. Eventually ctx->Texture.ReallyEnabled may become a boolean. --- src/mesa/main/state.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/mesa/main/state.c') diff --git a/src/mesa/main/state.c b/src/mesa/main/state.c index eeb73634549..bc0e0142139 100644 --- a/src/mesa/main/state.c +++ b/src/mesa/main/state.c @@ -1,4 +1,4 @@ -/* $Id: state.c,v 1.31 2000/10/18 15:02:59 brianp Exp $ */ +/* $Id: state.c,v 1.32 2000/10/20 19:54:49 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -853,6 +853,7 @@ void gl_update_state( GLcontext *ctx ) } if (ctx->NewState & (NEW_TEXTURING | NEW_TEXTURE_ENABLE)) { + ctx->Texture.MultiTextureEnabled = GL_FALSE; ctx->Texture.NeedNormals = GL_FALSE; gl_update_dirty_texobjs(ctx); ctx->Enabled &= ~(ENABLE_TEXGEN0 | ENABLE_TEXGEN1 | ENABLE_TEXGEN2); @@ -877,6 +878,10 @@ void gl_update_state( GLcontext *ctx ) ctx->Texture.NeedEyeCoords = GL_TRUE; } } + + if (i > 0 && ctx->Texture.Unit[i].ReallyEnabled) { + ctx->Texture.MultiTextureEnabled = GL_TRUE; + } } } -- cgit v1.2.3