summaryrefslogtreecommitdiff
path: root/progs/tests
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2004-01-31 19:15:43 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2004-01-31 19:15:43 +0000
commit919404fd1df30bbe5d391ddfbdd7ceb6d817525b (patch)
tree6e516fa623b4b9a674e1cd64506fce2656eb0800 /progs/tests
parent041e66b0d69b0b3288fbec8814fd1b941af9dbbe (diff)
enable program and arrays by default, minor clean-ups
Diffstat (limited to 'progs/tests')
-rw-r--r--progs/tests/vparray.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/progs/tests/vparray.c b/progs/tests/vparray.c
index 65a3bbfefc..1c513cf0f4 100644
--- a/progs/tests/vparray.c
+++ b/progs/tests/vparray.c
@@ -21,8 +21,8 @@ static GLint numverts;
static GLfloat xrot;
static GLfloat yrot;
-static GLboolean useArrays = GL_FALSE;
-static GLboolean useProgram = GL_FALSE;
+static GLboolean useArrays = GL_TRUE;
+static GLboolean useProgram = GL_TRUE;
static void read_surface( char *filename )
@@ -71,23 +71,18 @@ static void Display(void)
glEnableClientState( GL_VERTEX_ATTRIB_ARRAY0_NV );
glVertexAttribPointerNV( 2, 3, GL_FLOAT, 6 * sizeof(GLfloat), ((GLfloat *) data) + 3);
glEnableClientState( GL_VERTEX_ATTRIB_ARRAY2_NV);
-
- glDisableClientState( GL_VERTEX_ARRAY );
- glDisableClientState( GL_NORMAL_ARRAY );
}
else {
glVertexPointer( 3, GL_FLOAT, 6 * sizeof(GLfloat), data );
glEnableClientState( GL_VERTEX_ARRAY );
glNormalPointer( GL_FLOAT, 6 * sizeof(GLfloat), ((GLfloat *) data) + 3);
glEnableClientState( GL_NORMAL_ARRAY );
-
- glDisableClientState( GL_VERTEX_ATTRIB_ARRAY0_NV );
- glDisableClientState( GL_VERTEX_ATTRIB_ARRAY2_NV);
}
glDrawArrays(GL_TRIANGLE_STRIP, 0, numverts);
glDisableClientState( GL_VERTEX_ATTRIB_ARRAY0_NV );
+ glDisableClientState( GL_VERTEX_ATTRIB_ARRAY2_NV);
glDisableClientState( GL_VERTEX_ARRAY );
glDisableClientState( GL_NORMAL_ARRAY );
}