From http://www.jwz.org/xscreensaver/xscreensaver-5.35.tar.gz
[xscreensaver] / hacks / t3d.c
index 08df87132a658590d7dcbb0e83174b3f624430c1..6a7e0cdec898a4a88dca2d7bb758fe7fd08a2956 100644 (file)
                           of the command-line options provided by screenhack.c.
 */
 
-#ifndef HAVE_COCOA
+#ifndef HAVE_JWXYZ
 # define FASTDRAW
 # define FASTCOPY
-#endif /* !HAVE_COCOA */
+#endif /* !HAVE_JWXYZ */
 
 #include <stdio.h>
 #include <math.h>
@@ -325,7 +325,7 @@ initialize (struct state *st)
 
   st->planes=st->xgwa.depth;
 
-#ifdef HAVE_COCOA
+#ifdef HAVE_JWXYZ
 # define GXandInverted GXcopy  /* #### this can't be right, right? */
 #endif
  st->gc = XCreateGC (st->dpy, st->window, 0,  xgc);
@@ -563,10 +563,15 @@ fill_kugel(struct state *st, int i, Pixmap buf, int setcol)
          else if(-ra<40.0) inc=2;
          if(setcol)
            {
-             if (m==27) col=33;
+             if (m==27)
+                col=33;
              else
                col=(int)(m);
-             if (col>33) col=33;       col/=3;
+
+             if (col>33)
+                col=33;
+
+              col/=3;
              setink(st->colors[col].pixel);
            }