diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-03-05 14:02:26 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-03-05 14:02:26 -0800 |
commit | f25b794a26c6870318ffe6103113ee50521e728d (patch) | |
tree | 371b107934c84373dd587747e17fcaafc9f0bf11 /tests/cubegeom.c | |
parent | 230c0e80dfcd44870bec3254c399db430f6e1d98 (diff) | |
parent | 38278a6448b7ae7201643cd81047faf263d2385c (diff) |
Merge branch 'incoming'
Diffstat (limited to 'tests/cubegeom.c')
-rw-r--r-- | tests/cubegeom.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/cubegeom.c b/tests/cubegeom.c index 6158b124..787b8373 100644 --- a/tests/cubegeom.c +++ b/tests/cubegeom.c @@ -45,6 +45,8 @@ void verify() { int main(int argc, char *argv[]) { + int temp; // testing + SDL_Surface *screen; if ( SDL_Init(SDL_INIT_VIDEO) != 0 ) { printf("Unable to initialize SDL: %s\n", SDL_GetError()); @@ -124,7 +126,9 @@ int main(int argc, char *argv[]) glActiveTexture(GL_TEXTURE0); + glGetBooleanv(GL_VERTEX_ARRAY, &temp); assert(!temp); glEnableClientState(GL_VERTEX_ARRAY); + glGetBooleanv(GL_VERTEX_ARRAY, &temp); assert(temp); GLuint arrayBuffer, elementBuffer; glGenBuffers(1, &arrayBuffer); @@ -207,7 +211,6 @@ int main(int argc, char *argv[]) glNormalPointer(GL_BYTE, 32, (void*)12); glColorPointer(4, GL_UNSIGNED_BYTE, 32, (void*)28); - int temp; // test glGetPointerv, glGetIntegerv glGetPointerv(GL_VERTEX_ARRAY_POINTER, &temp); assert(temp == 0); glGetPointerv(GL_COLOR_ARRAY_POINTER, &temp); assert(temp == 28); glGetPointerv(GL_TEXTURE_COORD_ARRAY_POINTER, &temp); assert(temp == 16); @@ -220,6 +223,7 @@ int main(int argc, char *argv[]) glGetIntegerv(GL_TEXTURE_COORD_ARRAY_SIZE, &temp); assert(temp == 2); glGetIntegerv(GL_TEXTURE_COORD_ARRAY_TYPE, &temp); assert(temp == GL_FLOAT); glGetIntegerv(GL_TEXTURE_COORD_ARRAY_STRIDE, &temp); assert(temp == 32); + glGetBooleanv(GL_VERTEX_ARRAY, &temp); assert(temp); glBindTexture(GL_TEXTURE_2D, texture); // diffuse? glActiveTexture(GL_TEXTURE0); |