From 29f8dfd37a2fbf4190e551bef0b04ff1ae1fd7b6 Mon Sep 17 00:00:00 2001 From: Mitchell Stokes Date: Mon, 29 Jul 2013 22:31:32 +0000 Subject: BGE: Adding vsync control. Users can enable vsync, disable vsync, or use adaptive vsync via UI options in the render properties, or by using the new Python method bge.render.setVsync(). Win32 and X11 support are done via EXT_swap_control. Support for using EXT_swap_control on OS X still needs to be added to Ghost. --- intern/ghost/GHOST_IWindow.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'intern/ghost/GHOST_IWindow.h') diff --git a/intern/ghost/GHOST_IWindow.h b/intern/ghost/GHOST_IWindow.h index a2d3e9b91fb..35577075263 100644 --- a/intern/ghost/GHOST_IWindow.h +++ b/intern/ghost/GHOST_IWindow.h @@ -204,6 +204,19 @@ public: */ virtual GHOST_TSuccess swapBuffers() = 0; + /** + * Sets the swap interval for swapBuffers. + * \param interval The swap interval to use. + * \return A boolean success indicator. + */ + virtual GHOST_TSuccess setSwapInterval(int interval) = 0; + + /** + * Gets the current swap interval for swapBuffers. + * \return An integer. + */ + virtual int getSwapInterval() = 0; + /** * Activates the drawing context of this window. * \return A boolean success indicator. -- cgit v1.2.3