summaryrefslogtreecommitdiffstats
path: root/hacks/glx/flipflop.c
diff options
context:
space:
mode:
authorSimon Rettberg2019-02-18 11:55:41 +0100
committerSimon Rettberg2019-02-18 11:55:41 +0100
commitae69a754244c4e475c8d2591772ca8e005071d83 (patch)
tree58b3fa7abc2dcfe3c23e1c0ce108950c720826ab /hacks/glx/flipflop.c
parentUpdate gitignore (diff)
downloadxscreensaver-ae69a754244c4e475c8d2591772ca8e005071d83.tar.gz
xscreensaver-ae69a754244c4e475c8d2591772ca8e005071d83.tar.xz
xscreensaver-ae69a754244c4e475c8d2591772ca8e005071d83.zip
Update to 5.42
Diffstat (limited to 'hacks/glx/flipflop.c')
-rw-r--r--hacks/glx/flipflop.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/hacks/glx/flipflop.c b/hacks/glx/flipflop.c
index c26458c..fe1643b 100644
--- a/hacks/glx/flipflop.c
+++ b/hacks/glx/flipflop.c
@@ -456,7 +456,7 @@ draw_flipflop(ModeInfo *mi)
if(!c->glx_context || (textured && !c->got_texture))
return;
- glXMakeCurrent(disp, w, *(c->glx_context));
+ glXMakeCurrent(disp, w, *c->glx_context);
mi->polygon_count = display(mi);
@@ -474,10 +474,14 @@ ENTRYPOINT void
free_flipflop(ModeInfo *mi)
{
Flipflopcreen *c = &qs[MI_SCREEN(mi)];
+ if (!c->glx_context) return;
+ glXMakeCurrent (MI_DISPLAY(mi), MI_WINDOW(mi), *c->glx_context);
+ if(c->trackball) gltrackball_free(c->trackball);
if (c->sheet) {
randsheet_free(c->sheet);
free (c->sheet);
}
+ if (c->texid) glDeleteTextures (1, &c->texid);
}
/*** ADDED RANDSHEET FUNCTIONS ***/