diff options
Diffstat (limited to 'examples/pugl_shader_demo.c')
-rw-r--r-- | examples/pugl_shader_demo.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/pugl_shader_demo.c b/examples/pugl_shader_demo.c index 9ba3da0..2cdcb6e 100644 --- a/examples/pugl_shader_demo.c +++ b/examples/pugl_shader_demo.c @@ -470,7 +470,7 @@ updateTimeout(const PuglTestApp* const app) const double nextExposeTime = nextFrameEndTime - neededTime; const double timeUntilNext = nextExposeTime - now; - return timeUntilNext; + return fmax(0.0, (timeUntilNext * 0.9) - 0.001); } int @@ -505,7 +505,7 @@ main(int argc, char** argv) const double startTime = puglGetTime(app.world); PuglFpsPrinter fpsPrinter = {startTime}; while (!app.quit) { - puglUpdate(app.world, fmax(0.0, updateTimeout(&app))); + puglUpdate(app.world, updateTimeout(&app)); puglPrintFps(app.world, &fpsPrinter, &app.framesDrawn); } |