]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
one last try to beat the OSX texture scrolling bug (set activetexture
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Wed, 27 Feb 2008 11:52:29 +0000 (11:52 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Wed, 27 Feb 2008 11:52:29 +0000 (11:52 +0000)
and clientactivetexture - even though only the former is needed, and do
so before switching the matrixmode to texture)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8142 d7cf8633-e32d-0410-b094-e92efae38249

gl_backend.c

index fefdf7f3db32fa883290f9ca0508a9d607e187ac..8ea6717062e08eeb2c748b291d5a69859f3d7b96 100644 (file)
@@ -1825,8 +1825,9 @@ void R_Mesh_TexMatrix(unsigned int unitnum, const matrix4x4_t *matrix)
                        unit->matrix = *matrix;
                        CHECKGLERROR
                        Matrix4x4_ToArrayDoubleGL(&unit->matrix, glmatrix);
-                       qglMatrixMode(GL_TEXTURE);CHECKGLERROR
                        GL_ActiveTexture(unitnum);
+                       GL_ClientActiveTexture(unitnum);
+                       qglMatrixMode(GL_TEXTURE);CHECKGLERROR
                        qglLoadMatrixd(glmatrix);CHECKGLERROR
                        qglMatrixMode(GL_MODELVIEW);CHECKGLERROR
                }
@@ -1838,8 +1839,9 @@ void R_Mesh_TexMatrix(unsigned int unitnum, const matrix4x4_t *matrix)
                {
                        unit->texmatrixenabled = false;
                        CHECKGLERROR
-                       qglMatrixMode(GL_TEXTURE);CHECKGLERROR
                        GL_ActiveTexture(unitnum);
+                       GL_ClientActiveTexture(unitnum);
+                       qglMatrixMode(GL_TEXTURE);CHECKGLERROR
                        qglLoadIdentity();CHECKGLERROR
                        qglMatrixMode(GL_MODELVIEW);CHECKGLERROR
                }