summaryrefslogtreecommitdiffstats
path: root/hacks/glx/boing.c
diff options
context:
space:
mode:
Diffstat (limited to 'hacks/glx/boing.c')
-rw-r--r--hacks/glx/boing.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/hacks/glx/boing.c b/hacks/glx/boing.c
index 55a05f3..adaf96b 100644
--- a/hacks/glx/boing.c
+++ b/hacks/glx/boing.c
@@ -25,7 +25,6 @@
"*showFPS: False \n" \
"*wireframe: False \n" \
-# define free_boing 0
# define release_boing 0
#undef countof
#define countof(x) (sizeof((x))/sizeof((*x)))
@@ -595,7 +594,7 @@ draw_boing (ModeInfo *mi)
if (!bp->glx_context)
return;
- glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *(bp->glx_context));
+ glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *bp->glx_context);
mi->polygon_count = 0;
@@ -653,6 +652,16 @@ draw_boing (ModeInfo *mi)
glXSwapBuffers(dpy, window);
}
+
+ENTRYPOINT void
+free_boing (ModeInfo *mi)
+{
+ boing_configuration *bp = &bps[MI_SCREEN(mi)];
+ if (!bp->glx_context) return;
+ glXMakeCurrent(MI_DISPLAY(mi), MI_WINDOW(mi), *bp->glx_context);
+ if (bp->trackball) gltrackball_free (bp->trackball);
+}
+
XSCREENSAVER_MODULE ("Boing", boing)
#endif /* USE_GL */