DRI2: expose OML_sync_control if possible
authorJesse Barnes <jbarnes@virtuousgeek.org>
Fri, 5 Mar 2010 19:17:19 +0000 (11:17 -0800)
committerJesse Barnes <jbarnes@virtuousgeek.org>
Fri, 5 Mar 2010 19:22:05 +0000 (11:22 -0800)
If the server supports the OML related protocol, enable support for the
extension.

src/glx/dri2_glx.c

index 29d589cdb900f9fc86106e259ce0c3216ab259eb..d573e46296bf49fff72a0e5de5dde12490acd1bf 100644 (file)
@@ -613,6 +613,9 @@ dri2CreateScreen(__GLXscreenConfigs * psc, int screen,
 #ifdef X_DRI2SwapInterval
       psp->setSwapInterval = dri2SetSwapInterval;
       psp->getSwapInterval = dri2GetSwapInterval;
+#endif
+#if defined(X_DRI2GetMSC) && defined(X_DRI2WaitMSC) && defined(X_DRI2SwapInterval)
+      __glXEnableDirectExtension(psc, "GLX_OML_sync_control");
 #endif
    }