http://www.jwz.org/xscreensaver/xscreensaver-5.12.tar.gz
[xscreensaver] / hacks / glx / glblur.c
index 193da13f3e85fffe4d5a80c178661546e956ddab..f2edb3d9b858d38531876f3b7878fbe8dea606e8 100644 (file)
@@ -1,5 +1,5 @@
 /* glblur --- radial blur using GL textures
- * Copyright (c) 2002-2004 Jamie Zawinski <jwz@jwz.org>
+ * Copyright (c) 2002-2008 Jamie Zawinski <jwz@jwz.org>
  *
  * Permission to use, copy, modify, distribute, and sell this software and its
  * documentation for any purpose is hereby granted without fee, provided that
@@ -46,7 +46,7 @@
 
 #define DEF_SPIN        "XYZ"
 #define DEF_WANDER      "True"
-#define DEF_BLURSIZE    "15"
+#define DEF_BLUR_SIZE   "15"
 
 typedef struct metaball metaball;
 
@@ -99,7 +99,7 @@ static XrmOptionDescRec opts[] = {
 static argtype vars[] = {
   {&do_spin,   "spin",   "Spin",   DEF_SPIN,   t_String},
   {&do_wander, "wander", "Wander", DEF_WANDER, t_Bool},
-  {&blursize,  "blurSize","BlurSize", DEF_BLURSIZE,  t_Int},
+  {&blursize,  "blurSize","BlurSize", DEF_BLUR_SIZE,  t_Int},
 };
 
 ENTRYPOINT ModeSpecOpt glblur_opts = {countof(opts), opts, countof(vars), vars, NULL};
@@ -278,7 +278,7 @@ overlay_blur_texture (ModeInfo *mi)
   GLfloat inc = 0.02 * (25.0 / times);
 
   GLfloat spost = 0;               /* starting texture coordinate offset */
-  GLfloat alpha_inc = 0.9 / times;  /* transparency fade factor */
+  GLfloat alpha_inc;               /* transparency fade factor */
   GLfloat alpha = 0.2;             /* initial transparency */
 
   glDisable (GL_TEXTURE_GEN_S);
@@ -361,7 +361,9 @@ glblur_handle_event (ModeInfo *mi, XEvent *event)
     }
   else if (event->xany.type == ButtonPress &&
            (event->xbutton.button == Button4 ||
-            event->xbutton.button == Button5))
+            event->xbutton.button == Button5 ||
+            event->xbutton.button == Button6 ||
+            event->xbutton.button == Button7))
     {
       gltrackball_mousewheel (bp->trackball, event->xbutton.button, 10,
                               !!event->xbutton.state);