wrap angle value (Philipp Klaus Krause)
authorBrian Paul <brian.paul@tungstengraphics.com>
Sat, 23 Oct 2004 18:55:48 +0000 (18:55 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Sat, 23 Oct 2004 18:55:48 +0000 (18:55 +0000)
progs/xdemos/glxgears.c

index 5969151..a82a0b9 100644 (file)
@@ -424,6 +424,8 @@ event_loop(Display *dpy, Window win)
 
       /* next frame */
       angle += 2.0;
+      if (angle > 3600.0)
+       angle -= 3600.0;
 
       draw();
       glXSwapBuffers(dpy, win);