summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-03-25 10:25:29 -0600
committerBrian <[email protected]>2007-03-25 10:25:29 -0600
commit6fda763989f9102399407098773de227abba822c (patch)
treef4ea4bf488db3908d0fc5b3d97c045da13aa7cf9
parenta1ea7812b2b8869b60877995fdb957e9539309bd (diff)
destroy window on exit
-rw-r--r--progs/tests/fbotest2.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/progs/tests/fbotest2.c b/progs/tests/fbotest2.c
index c3117b0f767..18f28972b6e 100644
--- a/progs/tests/fbotest2.c
+++ b/progs/tests/fbotest2.c
@@ -13,6 +13,7 @@
#include <math.h>
#include <GL/glut.h>
+static int Win = 0;
static int Width = 400, Height = 400;
static GLuint MyFB, ColorRb, DepthRb;
static GLboolean Animate = GL_TRUE;
@@ -110,6 +111,7 @@ CleanUp(void)
assert(!glIsFramebufferEXT(MyFB));
assert(!glIsRenderbufferEXT(ColorRb));
assert(!glIsRenderbufferEXT(DepthRb));
+ glutDestroyWindow(Win);
exit(0);
}
@@ -187,7 +189,7 @@ main( int argc, char *argv[] )
glutInitWindowPosition( 0, 0 );
glutInitWindowSize(Width, Height);
glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE );
- glutCreateWindow(argv[0]);
+ Win = glutCreateWindow(argv[0]);
glutReshapeFunc( Reshape );
glutKeyboardFunc( Key );
glutDisplayFunc( Display );