* Kristian Høgsberg (krh@redhat.com)
*/
-#ifdef GLX_DIRECT_RENDERING
+#if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
#include <unistd.h>
#include <dlfcn.h>
/* Bind DRI1 specific extensions */
_X_HIDDEN void
-driBindExtensions(__GLXscreenConfigs *psc)
+driBindExtensions(__GLXscreenConfigs *psc, const __DRIextension **extensions)
{
- const __DRIextension **extensions;
int i;
- extensions = psc->core->getExtensions(psc->__driScreen);
-
for (i = 0; extensions[i]; i++) {
#ifdef __DRI_SWAP_CONTROL
/* No DRI2 support for swap_control at the moment, since SwapBuffers
/* Bind DRI2 specific extensions */
_X_HIDDEN void
-dri2BindExtensions(__GLXscreenConfigs *psc)
+dri2BindExtensions(__GLXscreenConfigs *psc,
+ const __DRIextension **extensions)
{
- const __DRIextension **extensions;
int i;
- extensions = psc->core->getExtensions(psc->__driScreen);
-
for (i = 0; extensions[i]; i++) {
#ifdef __DRI_TEX_BUFFER
if ((strcmp(extensions[i]->name, __DRI_TEX_BUFFER) == 0)) {
/* Bind extensions common to DRI1 and DRI2 */
_X_HIDDEN void
-driBindCommonExtensions(__GLXscreenConfigs *psc)
+driBindCommonExtensions(__GLXscreenConfigs *psc,
+ const __DRIextension **extensions)
{
- const __DRIextension **extensions;
int i;
- extensions = psc->core->getExtensions(psc->__driScreen);
-
for (i = 0; extensions[i]; i++) {
#ifdef __DRI_COPY_SUB_BUFFER
if (strcmp(extensions[i]->name, __DRI_COPY_SUB_BUFFER) == 0) {
}
#endif
-#ifdef __DRI_ALLOCATE
- if (strcmp(extensions[i]->name, __DRI_ALLOCATE) == 0) {
- psc->allocate = (__DRIallocateExtension *) extensions[i];
- __glXEnableDirectExtension(psc, "GLX_MESA_allocate_memory");
- }
-#endif
-
#ifdef __DRI_FRAME_TRACKING
if (strcmp(extensions[i]->name, __DRI_FRAME_TRACKING) == 0) {
psc->frameTracking = (__DRIframeTrackingExtension *) extensions[i];