summaryrefslogtreecommitdiff
path: root/gdk/gdkframetimings.h
diff options
context:
space:
mode:
authorOwen W. Taylor <otaylor@fishsoup.net>2012-11-14 16:08:08 -0500
committerOwen W. Taylor <otaylor@fishsoup.net>2013-02-14 17:19:50 -0500
commit58b5811d03ded179b285727407b6a6be3d4d0734 (patch)
tree57bb0e1f18a863a6abb1958b871a33b4b784510d /gdk/gdkframetimings.h
parentdc6dedab4dfdff5d067ba9f8c88d6a48cf0af143 (diff)
downloadgtk+-58b5811d03ded179b285727407b6a6be3d4d0734.tar.gz
Add gdk_frame_timings_get/set_slept_before()
Add functions that tell us whether the main loop slept before we drew a frame. Blocking with the frame clock frozen doesn't count as sleeping. We'll use this to advertise to the compositor whether we are drawing as fast as possible (and it should do the same) or timing frames carefully (and it should do the same.) https://bugzilla.gnome.org/show_bug.cgi?id=685460
Diffstat (limited to 'gdk/gdkframetimings.h')
-rw-r--r--gdk/gdkframetimings.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/gdk/gdkframetimings.h b/gdk/gdkframetimings.h
index 7fddbd4a6d..53dbffbd06 100644
--- a/gdk/gdkframetimings.h
+++ b/gdk/gdkframetimings.h
@@ -45,6 +45,10 @@ gboolean gdk_frame_timings_get_complete (GdkFrameTimings *timin
void gdk_frame_timings_set_complete (GdkFrameTimings *timings,
gboolean complete);
+gboolean gdk_frame_timings_get_slept_before (GdkFrameTimings *timings);
+void gdk_frame_timings_set_slept_before (GdkFrameTimings *timings,
+ gboolean slept_before);
+
gint64 gdk_frame_timings_get_frame_time (GdkFrameTimings *timings);
void gdk_frame_timings_set_frame_time (GdkFrameTimings *timings,
gint64 frame_time);