From http://www.jwz.org/xscreensaver/xscreensaver-5.18.tar.gz
[xscreensaver] / hacks / bouboule.c
index 15bf2278441b01174e98bbb352c5f0cced89104d..081ba4851c57dc286b35fd16bce13c3a0e2c91ad 100644 (file)
@@ -87,7 +87,6 @@ static const char sccsid[] = "@(#)bouboule.c  4.00 97/01/01 xlockmore";
                                        "*fpsSolid:             true    \n"
 
 # define SMOOTH_COLORS
-# define reshape_bouboule 0
 # define bouboule_handle_event 0
 # include "xlockmore.h"                                /* from the xscreensaver distribution */
 #else  /* !STANDALONE */
@@ -838,6 +837,24 @@ release_bouboule(ModeInfo * mi)
        }
 }
 
+ENTRYPOINT void
+reshape_bouboule(ModeInfo * mi, int width, int height)
+{
+       StarField  *sp = &starfield[MI_SCREEN(mi)];
+       sp->width  = width;
+       sp->height = height;
+    sininit(&sp->x,
+        sp->x.alpha, sp->x.step,
+        ((double) sp->width) / 4.0,
+        3.0 * ((double) sp->width) / 4.0,
+        POSCANRAND);
+    sininit(&sp->y,
+        sp->y.alpha, sp->y.step,
+        ((double) sp->height) / 4.0,
+        3.0 * ((double) sp->height) / 4.0,
+        POSCANRAND);
+}
+
 ENTRYPOINT void
 refresh_bouboule(ModeInfo * mi)
 {