From http://www.jwz.org/xscreensaver/xscreensaver-5.38.tar.gz
[xscreensaver] / hacks / thornbird.c
index 2ebbf17297db01dcda1ee404c6c6cb4e4af0e437..07e0cbde5e5dd06dc5ed6e366b97e962dc4e24b2 100644 (file)
@@ -37,9 +37,11 @@ static const char sccsid[] = "@(#)thornbird.c        5.00 2000/11/01 xlockmore";
                                         "*ncolors: 64    \n" \
                                         "*fpsSolid: true    \n" \
                                        "*ignoreRotation: True \n" \
+                                   "*lowrez: True \n" \
 
 # define BRIGHT_COLORS
 # define release_thornbird 0
+# define reshape_thornbird 0
 # define thornbird_handle_event 0
 # include "xlockmore.h"                /* in xscreensaver distribution */
 #else /* STANDALONE */
@@ -54,7 +56,7 @@ ENTRYPOINT ModeSpecOpt thornbird_opts =
 #ifdef USE_MODULES
 ModStruct   thornbird_description =
 {"thornbird", "init_thornbird", "draw_thornbird", (char *) NULL,
- "refresh_thornbird", "init_thornbird", (char *) NULL, &thornbird_opts,
+ "refresh_thornbird", "init_thornbird", "free_thornbird", &thornbird_opts,
  1000, 800, 16, 1, 64, 1.0, "",
  "Shows an animated Bird in a Thorn Bush fractal map", 0, NULL};
 
@@ -91,7 +93,7 @@ typedef struct {
 
 static thornbirdstruct *thornbirds = (thornbirdstruct *) NULL;
 
-static void
+ENTRYPOINT void
 free_thornbird(ModeInfo * mi)
 {
        thornbirdstruct *hp = &thornbirds[MI_SCREEN(mi)];
@@ -111,7 +113,7 @@ init_thornbird (ModeInfo * mi)
 {
        thornbirdstruct *hp;
 
-       MI_INIT (mi, thornbirds, free_thornbird);
+       MI_INIT (mi, thornbirds);
        hp = &thornbirds[MI_SCREEN(mi)];
 
 
@@ -248,18 +250,13 @@ draw_thornbird(ModeInfo * mi)
        hp->inc++;
 }
 
-ENTRYPOINT void
-reshape_thornbird(ModeInfo * mi, int width, int height)
-{
-  XClearWindow (MI_DISPLAY (mi), MI_WINDOW(mi));
-  init_thornbird (mi);
-}
-
+#ifndef STANDALONE
 ENTRYPOINT void
 refresh_thornbird (ModeInfo * mi)
 {
        MI_CLEARWINDOW(mi);
 }
+#endif
 
 
 XSCREENSAVER_MODULE ("Thornbird", thornbird)