mirror of
https://github.com/brl/mutter.git
synced 2024-12-25 12:32:05 +00:00
clutter/frame-clock: Comment common case of next presentation time
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1707>
This commit is contained in:
parent
bc7c56fa74
commit
ed93a11de6
@ -246,6 +246,23 @@ calculate_next_update_time_us (ClutterFrameClock *frame_clock,
|
||||
if (min_render_time_allowed_us > max_render_time_allowed_us)
|
||||
min_render_time_allowed_us = max_render_time_allowed_us;
|
||||
|
||||
/*
|
||||
* The common case is that the next presentation happens 1 refresh interval
|
||||
* after the last presentation:
|
||||
*
|
||||
* last_presentation_time_us
|
||||
* / next_presentation_time_us
|
||||
* / /
|
||||
* / /
|
||||
* |--|--o----|-------|--> presentation times
|
||||
* | | \ |
|
||||
* | | now_us
|
||||
* | \______/
|
||||
* | refresh_interval_us
|
||||
* |
|
||||
* 0
|
||||
*
|
||||
*/
|
||||
last_presentation_time_us = frame_clock->last_presentation_time_us;
|
||||
next_presentation_time_us = last_presentation_time_us + refresh_interval_us;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user