[gtk/wip/chergert/fix-macos-fps-calculation] macos: fix fps calculation for frame timings
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/fix-macos-fps-calculation] macos: fix fps calculation for frame timings
- Date: Fri, 16 Oct 2020 04:05:21 +0000 (UTC)
commit 7ae8ed82c9ce2656e0301b1d5161c683695b0c00
Author: Christian Hergert <chergert redhat com>
Date: Thu Oct 15 21:04:51 2020 -0700
macos: fix fps calculation for frame timings
We need to mark the timings as complete after adding the
presentation time so that we have a valid FPS for the overlay
widget and/or fishbowl demo.
gdk/macos/gdkmacossurface.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/gdk/macos/gdkmacossurface.c b/gdk/macos/gdkmacossurface.c
index ec0fb41560..9925407d46 100644
--- a/gdk/macos/gdkmacossurface.c
+++ b/gdk/macos/gdkmacossurface.c
@@ -713,7 +713,10 @@ _gdk_macos_surface_thaw (GdkMacosSurface *self,
timings = gdk_frame_clock_get_timings (frame_clock, self->pending_frame_counter);
if (timings != NULL)
- timings->presentation_time = presentation_time - refresh_interval;
+ {
+ timings->presentation_time = presentation_time - refresh_interval;
+ timings->complete = TRUE;
+ }
self->pending_frame_counter = 0;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]