-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Previously Catacomb would always start compositing 10ms before the vblank. However in some instances, like with a large number of surfaces, rendering could exceed that deadline and cause Catacomb to miss the vblank entirely. This patch adds a dynamic scheduling model, which uses the average rendering time and the last 16 frames to predict the next frame's rendering time. Since rendering does tend to fluctuate and Catacomb is lacking insight into when rendering actually completed, a buffer is added on top of the prediction. Since compositing times in the worst-case are very high, the predictions generally exceed the vblank interval, effectively making this solution identical to always compositing right after the vblank. However under ideal circumstances this solution manages to provide at least a couple milliseconds for fast clients to render, without significantly affecting the worst-case. This also can likely be improved in the future with more insight into the rendering pipeline. Closes #146.
- Loading branch information
1 parent
b0e0323
commit 0409604
Showing
2 changed files
with
65 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters