projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cb45324
)
demos: all glutDestroyWindow() upon exit to test query object clean-up
author
Brian Paul
<brian.paul@tungstengraphics.com>
Thu, 18 Dec 2008 16:48:20 +0000
(09:48 -0700)
committer
Brian Paul
<brian.paul@tungstengraphics.com>
Thu, 18 Dec 2008 18:11:59 +0000
(11:11 -0700)
progs/demos/arbocclude.c
patch
|
blob
|
history
diff --git
a/progs/demos/arbocclude.c
b/progs/demos/arbocclude.c
index ddbb1f1b759bb37b19ec8b75d2d805e449be8fa9..6bf4fd218b900052b1237162c6c1a204d11a7f55 100644
(file)
--- a/
progs/demos/arbocclude.c
+++ b/
progs/demos/arbocclude.c
@@
-37,7
+37,7
@@
static GLboolean Anim = GL_TRUE;
static GLfloat Xpos = 0;
static GLuint OccQuery;
-
+static GLint Win = 0;
static void
@@
-204,6
+204,7
@@
static void Key( unsigned char key, int x, int y )
(void) y;
switch (key) {
case 27:
+ glutDestroyWindow(Win);
exit(0);
break;
case ' ':
@@
-271,7
+272,7
@@
int main( int argc, char *argv[] )
glutInitWindowPosition( 0, 0 );
glutInitWindowSize( 400, 400 );
glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH );
- glutCreateWindow(argv[0]);
+
Win =
glutCreateWindow(argv[0]);
glutReshapeFunc( Reshape );
glutKeyboardFunc( Key );
glutSpecialFunc( SpecialKey );