hi!
i’m using multitexturing & vertex arrays…
at the beginning i associate vertex array, then texture coordinate 1st array, then texture coordinate 2nd array
doing like this:
glVertexPointer (3, GL_FLOAT, sizeof(point), vertexArray); glClientActiveTextureARB(GL_TEXTURE0_ARB);
glTexCoordPointer (2, GL_FLOAT, sizeof(texCoord), texCoords_1);
glClientActiveTextureARB(GL_TEXTURE1_ARB);
glTexCoordPointer (2, GL_FLOAT, sizeof(texCoord), texCoords_2);
then enable both texture units:
glActiveTextureARB ( GL_TEXTURE0_ARB );
glEnable ( GL_TEXTURE_2D);
glActiveTextureARB ( GL_TEXTURE1_ARB );
glEnable ( GL_TEXTURE_2D);
after this however in some cases i want ot use only 1 texture unit, but it crashes when trying to disable 2nd unit:
glActiveTextureARB ( GL_TEXTURE1_ARB );
glDisable(GL_TEXTURE_2D);
need help!