hrev48356 adds 1 changeset to branch 'master' old head: 21e5fc49a70cccc13e033a1e62b281dab27b1ea2 new head: d433a61aa2532b4e00b7ddc66e6059ab296fbb6f overview: http://cgit.haiku-os.org/haiku/log/?qt=range&q=d433a61+%5E21e5fc4 ---------------------------------------------------------------------------- d433a61: GLTeapot: wait for retrace. Rendering at 200+fps is useless when your display can't handle it. Now we can spin many more teapots while demo'ing Haiku without wasting as much CPU. [ Adrien Destugues <pulkomandy@xxxxxxxxx> ] ---------------------------------------------------------------------------- Revision: hrev48356 Commit: d433a61aa2532b4e00b7ddc66e6059ab296fbb6f URL: http://cgit.haiku-os.org/haiku/commit/?id=d433a61 Author: Adrien Destugues <pulkomandy@xxxxxxxxx> Date: Fri Nov 21 12:31:19 2014 UTC ---------------------------------------------------------------------------- 1 file changed, 2 insertions(+) src/apps/glteapot/ObjectView.cpp | 2 ++ ---------------------------------------------------------------------------- diff --git a/src/apps/glteapot/ObjectView.cpp b/src/apps/glteapot/ObjectView.cpp index 5c3e0ff..83645e4 100644 --- a/src/apps/glteapot/ObjectView.cpp +++ b/src/apps/glteapot/ObjectView.cpp @@ -113,6 +113,7 @@ static int32 simonThread(void* cookie) { ObjectView* objectView = reinterpret_cast<ObjectView*>(cookie); + BScreen screen(objectView->Window()); int noPause = 0; while (acquire_sem_etc(objectView->quittingSem, 1, B_TIMEOUT, 0) == B_NO_ERROR) { @@ -125,6 +126,7 @@ simonThread(void* cookie) noPause = 0; waitEvent(objectView->drawEvent); } + screen.WaitForRetrace(); } return 0; }