- glRotatef(current_device_rotation(), 0, 0, 1);
+
+# ifdef HAVE_MOBILE
+ {
+ int rot = current_device_rotation();
+
+ if (rot == 180 || rot == -180) /* so much WTF */
+ glRotatef (-68, 1, 0, 0);
+ else if (rot == 90 || rot == -270)
+ glRotatef (68, 0, 1, 0);
+ else if (rot == -90 || rot == 270)
+ glRotatef (-68, 0, 1, 0);
+
+ glRotatef (rot, 0, 0, 1); /* right side up */
+ }
+# endif
+