* other special, indirect and consequential damages.
*/
-#if !defined( lint ) && !defined( SABER )
+#if 0
static const char sccsid[] = "@(#)bouboule.c 4.00 97/01/01 xlockmore";
-
#endif
/*-
*/
#ifdef STANDALONE
-# define PROGCLASS "Bouboule"
-# define HACK_INIT init_bouboule
-# define HACK_DRAW draw_bouboule
-# define bouboule_opts xlockmore_opts
# define DEFAULTS "*count: 100 \n" \
"*size: 15 \n" \
- "*delay: 5000 \n" \
+ "*delay: 20000 \n" \
"*ncolors: 64 \n" \
- "*use3d: False \n" \
+ "*use3d: True \n" \
"*delta3d: 1.5 \n" \
"*right3d: red \n" \
"*left3d: blue \n" \
"*both3d: magenta \n" \
- "*none3d: black \n"
+ "*none3d: black \n" \
+ "*fpsSolid: true \n" \
+ "*ignoreRotation: True \n"
# define SMOOTH_COLORS
+# define bouboule_handle_event 0
# include "xlockmore.h" /* from the xscreensaver distribution */
#else /* !STANDALONE */
# include "xlock.h" /* from the xlockmore distribution */
+# define ENTRYPOINT /**/
#endif /* !STANDALONE */
-ModeSpecOpt bouboule_opts = {
+ENTRYPOINT ModeSpecOpt bouboule_opts = {
0, NULL, 0, NULL, NULL };
#define USEOLDXARCS 1 /* If 1, we use old xarcs list for erasing.
}
}
+
/***************/
-void
+ENTRYPOINT void
init_bouboule(ModeInfo * mi)
/***************/
}
/****************/
-void
+ENTRYPOINT void
draw_bouboule(ModeInfo * mi)
/****************/
Star *star;
XArc *arc = NULL, *arcleft = NULL;
+#ifdef HAVE_COCOA /* Don't second-guess Quartz's double-buffering */
+ XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi));
+#endif
+
#if (ADAPT_ERASE == 1)
struct timeval tv1;
struct timeval tv2;
}
}
-void
+ENTRYPOINT void
release_bouboule(ModeInfo * mi)
{
if (starfield != NULL) {
}
}
-void
+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)
{
/* Do nothing, it will refresh by itself */
}
+
+XSCREENSAVER_MODULE ("Bouboule", bouboule)