OSDN Git Service

demos: add some fflushes for windows
authorKeith Whitwell <keithw@vmware.com>
Tue, 24 Feb 2009 12:02:24 +0000 (12:02 +0000)
committerKeith Whitwell <keithw@vmware.com>
Tue, 24 Feb 2009 12:14:50 +0000 (12:14 +0000)
progs/demos/arbfplight.c
progs/demos/arbfslight.c
progs/demos/fslight.c
progs/demos/gearbox.c
progs/demos/gears.c
progs/demos/geartrain.c
progs/demos/gloss.c
progs/demos/glslnoise.c
progs/demos/reflect.c
progs/demos/streaming_rect.c
progs/demos/texcyl.c

index 401bfb4..7b7a12b 100644 (file)
@@ -92,6 +92,7 @@ static void Redisplay( void )
         GLfloat seconds = (t - T0) / 1000.0;
         GLfloat fps = Frames / seconds;
         printf("%d frames in %6.3f seconds = %6.3f FPS\n", Frames, seconds, fps);
+         fflush(stdout);
         T0 = t;
         Frames = 0;
       }
index a84491d..275c851 100644 (file)
@@ -105,6 +105,7 @@ static void Redisplay (void)
                        GLfloat seconds = (GLfloat) (t - t0) / 1000.0f;
                        GLfloat fps = frames / seconds;
                        printf ("%d frames in %6.3f seconds = %6.3f FPS\n", frames, seconds, fps);
+                        fflush(stdout);
                        t0 = t;
                        frames = 0;
                }
index e79b5cc..41a13cc 100644 (file)
@@ -105,6 +105,7 @@ Redisplay(void)
          GLfloat fps = frames / seconds;
          printf("%d frames in %6.3f seconds = %6.3f FPS\n",
                 frames, seconds, fps);
+         fflush(stdout);
          t0 = t;
          frames = 0;
       }
index 35bde04..2dcf32f 100644 (file)
@@ -314,6 +314,7 @@ draw(void)
          GLfloat seconds = (t - T0) / 1000.0;
          GLfloat fps = Frames / seconds;
          printf("%d frames in %6.3f seconds = %6.3f FPS\n", Frames, seconds, fps);
+         fflush(stdout);
          T0 = t;
          Frames = 0;
       }
index 2a9fefe..6016162 100644 (file)
@@ -219,6 +219,7 @@ draw(void)
       GLfloat seconds = (t - T0) / 1000.0;
       GLfloat fps = Frames / seconds;
       printf("%d frames in %6.3f seconds = %6.3f FPS\n", Frames, seconds, fps);
+      fflush(stdout);
       T0 = t;
       Frames = 0;
       if ((t >= 999.0 * autoexit) && (autoexit)) {
index 8363f2a..8fe405e 100644 (file)
@@ -905,6 +905,7 @@ draw (void)
            GLfloat seconds = (t - T0) / 1000.0;
            GLfloat fps = Frames / seconds;
            printf("%d frames in %g seconds = %g FPS\n", Frames, seconds, fps);
+            fflush(stdout);
            T0 = t;
            Frames = 0;
        }
index b2126e3..69694b2 100644 (file)
@@ -132,6 +132,7 @@ static void Display( void )
          GLfloat seconds = (t - T0) / 1000.0;
          GLfloat fps = Frames / seconds;
          printf("%d frames in %g seconds = %g FPS\n", Frames, seconds, fps);
+         fflush(stdout);
          T0 = t;
          Frames = 0;
       }
index 4ee1292..e972b62 100644 (file)
@@ -65,6 +65,7 @@ static void Redisplay (void)
       GLfloat seconds = (GLfloat) (t - t0) / 1000.0f;
       GLfloat fps = frames / seconds;
       printf ("%d frames in %6.3f seconds = %6.3f FPS\n", frames, seconds, fps);
+      fflush(stdout);
       t0 = t;
       frames = 0;
    }
index 0bec066..b72af12 100644 (file)
@@ -401,6 +401,7 @@ DrawWindow(void)
          GLfloat seconds = (t - t0) / 1000.0;
          GLfloat fps = frames / seconds;
          printf("%d frames in %g seconds = %g FPS\n", frames, seconds, fps);
+         fflush(stdout);
          t0 = t;
          frames = 0;
       }
index 294f9c3..f65ac4c 100644 (file)
@@ -153,6 +153,7 @@ static void Display( void )
 
       GLfloat fps = Frames / seconds;
       printf("%d frames in %6.3f seconds = %6.3f FPS\n", Frames, seconds, fps);
+      fflush(stdout);
 
       drift_increment = 2.2 * seconds / Frames;
       T0 = t;
index e3b0303..0e6089b 100644 (file)
@@ -79,6 +79,7 @@ static void Display( void )
          GLfloat seconds = (t - T0) / 1000.0;
          GLfloat fps = Frames / seconds;
          printf("%d frames in %g seconds = %g FPS\n", Frames, seconds, fps);
+         fflush(stdout);
          T0 = t;
          Frames = 0;
       }