From 973da83f6237b5af4a9ee77f32fdfa5c04ecabc8 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 12 Sep 2003 15:03:12 +0000 Subject: Allow glTexImage1/2/3D to specify width/height/depth = 0. This allows texture state to be resettable to default state. Not allowed according to the spec, but allowed by all other OpenGL libs. --- src/mesa/main/texstate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mesa/main/texstate.c') diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c index 133b957aa5..95009a23a5 100644 --- a/src/mesa/main/texstate.c +++ b/src/mesa/main/texstate.c @@ -2716,6 +2716,7 @@ update_texture_state( GLcontext *ctx ) struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit]; GLuint enableBits; + texUnit->_Current = NULL; texUnit->_ReallyEnabled = 0; texUnit->_GenFlags = 0; @@ -2789,8 +2790,7 @@ update_texture_state( GLcontext *ctx ) } if (!texUnit->_ReallyEnabled) { - texUnit->_Current = NULL; - continue; + continue; } if (texUnit->_ReallyEnabled) -- cgit v1.2.3