From 150d98bd15d16f6408cfa91d85f33e12dc68992b Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Fri, 19 Jan 2024 09:56:30 +0300 Subject: [PATCH] ref: gl: fix stuck single lightmap texture object when using VBO after updating lightmap --- ref/gl/gl_rsurf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ref/gl/gl_rsurf.c b/ref/gl/gl_rsurf.c index 98a1bca5..64f13c41 100644 --- a/ref/gl/gl_rsurf.c +++ b/ref/gl/gl_rsurf.c @@ -2993,7 +2993,7 @@ void R_ClearVBOState( qboolean drawlightmap, qboolean drawtextures ) if( drawlightmap ) { // reset states - GL_SelectTexture( XASH_TEXTURE1 ); + GL_Bind( XASH_TEXTURE1, tr.defaultTexture ); // force reset tmu in case we have only one lightmap pglDisableClientState( GL_TEXTURE_COORD_ARRAY ); pglDisable( GL_TEXTURE_2D ); if( drawtextures )