diff options
author | Jesse Barnes <[email protected]> | 2010-03-08 11:30:26 -0800 |
---|---|---|
committer | Jesse Barnes <[email protected]> | 2010-03-08 11:31:26 -0800 |
commit | f2a035e5d8dab1785b31f3e43175595d40e75148 (patch) | |
tree | bbfb3d8d5a0f60bbac80e693a54b92679eaa6d22 | |
parent | e5923a1240d8b32f5af080b0b4191d3b9299a630 (diff) |
xdemos/omlsync: improve OML WaitMsc test
Use the divisor/remainder for the WaitForMscOML call if a wait_interval
is passed. Allows for testing of the WaitMSC paths in the server & DDX.
-rw-r--r-- | progs/xdemos/omlsync.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/progs/xdemos/omlsync.c b/progs/xdemos/omlsync.c index a2baf4ad720..061d6c68613 100644 --- a/progs/xdemos/omlsync.c +++ b/progs/xdemos/omlsync.c @@ -249,11 +249,13 @@ int main(int argc, char *argv[]) glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); glRectf(0, 0, width, height); - glXSwapBuffersMscOML(disp, winGL, 0, divisor, remainder); - - if (wait_interval) { + if (!wait_interval) + glXSwapBuffersMscOML(disp, winGL, 0, divisor, + remainder); + else { glXWaitForMscOML(disp, winGL, msc + wait_interval, - 0, 0, &ust, &msc, &sbc); + divisor, remainder, &ust, &msc, &sbc); + glXSwapBuffersMscOML(disp, winGL, 0, 0, 0); } } |