diff options
author | Brian Paul <[email protected]> | 2009-12-09 14:53:53 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2009-12-09 14:53:53 -0700 |
commit | 288ea9770a2c9323ffa9a4b9f3a818d8aa02acd9 (patch) | |
tree | c3c7e4c384d908494b3c8261c01f2f296b2b4b50 | |
parent | d7dbc666367438ee9efe748505907b36bba6b66a (diff) |
progs/demos: call glutDestroyWindow() in gloss.c
-rw-r--r-- | progs/demos/gloss.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/progs/demos/gloss.c b/progs/demos/gloss.c index 69694b23a09..56d48b5a9ed 100644 --- a/progs/demos/gloss.c +++ b/progs/demos/gloss.c @@ -41,6 +41,7 @@ /* for convolution */ #define FILTER_SIZE 7 +static GLint Win; static GLint WinWidth = 500, WinHeight = 500; static GLuint CylinderObj = 0; static GLuint TeapotObj = 0; @@ -215,6 +216,7 @@ static void Key( unsigned char key, int x, int y ) ToggleAnimate(); break; case 27: + glutDestroyWindow(Win); exit(0); break; } @@ -439,7 +441,7 @@ int main( int argc, char *argv[] ) glutInit( &argc, argv ); glutInitWindowSize(WinWidth, WinHeight); glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH ); - glutCreateWindow(argv[0] ); + Win = glutCreateWindow(argv[0] ); glewInit(); glutReshapeFunc( Reshape ); glutKeyboardFunc( Key ); |