From http://www.jwz.org/xscreensaver/xscreensaver-5.35.tar.gz
[xscreensaver] / hacks / glx / geodesic.c
index 383e3045d0b6a7be2cf8eb4da00b671c59e4a623..b22b065eee8d730eb58d6acc58c977e0b12e32ae 100644 (file)
@@ -11,7 +11,8 @@
 
 #define DEFAULTS       "*delay:        30000       \n" \
                        "*count:        4           \n" \
-                       "*showFPS:      False       \n"
+                       "*showFPS:      False       \n" \
+                       "*suppressRotationAnimation: True\n" \
 
 # define refresh_geodesic 0
 # define release_geodesic 0
@@ -468,6 +469,14 @@ reshape_geodesic (ModeInfo *mi, int width, int height)
              0.0, 0.0, 0.0,
              0.0, 1.0, 0.0);
 
+# ifdef HAVE_MOBILE    /* Keep it the same relative size when rotated. */
+  {
+    int o = (int) current_device_rotation();
+    if (o != 0 && o != 180 && o != -180)
+      glScalef (1/h, 1/h, 1/h);
+  }
+# endif
+
   glClear(GL_COLOR_BUFFER_BIT);
 }