From 512539c48ce70b2c6cb4038eb25d283776e7541d Mon Sep 17 00:00:00 2001 From: Lee Salzman Date: Fri, 12 Sep 2008 00:59:54 +0000 Subject: [PATCH] disable texture coordinates when not needed git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2535 e016b1c5-ed68-44aa-a2f7-31cac88cffde --- source/src/vertmodel.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/source/src/vertmodel.h b/source/src/vertmodel.h index 27174166..e1f1e42c 100644 --- a/source/src/vertmodel.h +++ b/source/src/vertmodel.h @@ -184,7 +184,15 @@ struct vertmodel : model glVertexPointer(3, GL_FLOAT, sizeof(vec), dynbuf); lastvertexarray = dynbuf; } - if(lasttexcoordarray != tcverts) + if(as.anim&ANIM_NOSKIN && !isstat) + { + if(lasttexcoordarray) + { + glDisableClientState(GL_TEXTURE_COORD_ARRAY); + lasttexcoordarray = NULL; + } + } + else if(lasttexcoordarray != tcverts) { if(!lasttexcoordarray) glEnableClientState(GL_TEXTURE_COORD_ARRAY); glTexCoordPointer(2, GL_FLOAT, sizeof(tcvert), tcverts);