egl/wayland: don't populate dri2_dpy->dri2_loader_extension

Analogous to the earlier android patch.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
This commit is contained in:
Emil Velikov 2016-08-16 18:21:48 +01:00 committed by Emil Velikov
parent 31ef5d4452
commit d2d579da7e
1 changed files with 9 additions and 7 deletions

View File

@ -581,6 +581,14 @@ dri2_wl_flush_front_buffer(__DRIdrawable * driDrawable, void *loaderPrivate)
(void) loaderPrivate;
}
static const __DRIdri2LoaderExtension dri2_loader_extension = {
.base = { __DRI_DRI2_LOADER, 3 },
.getBuffers = dri2_wl_get_buffers,
.flushFrontBuffer = dri2_wl_flush_front_buffer,
.getBuffersWithFormat = dri2_wl_get_buffers_with_format,
};
static const __DRIimageLoaderExtension image_loader_extension = {
.base = { __DRI_IMAGE_LOADER, 1 },
@ -1141,13 +1149,7 @@ dri2_initialize_wayland_drm(_EGLDriver *drv, _EGLDisplay *disp)
/* render nodes cannot use Gem names, and thus do not support
* the __DRI_DRI2_LOADER extension */
if (!dri2_dpy->is_render_node) {
dri2_dpy->dri2_loader_extension.base.name = __DRI_DRI2_LOADER;
dri2_dpy->dri2_loader_extension.base.version = 3;
dri2_dpy->dri2_loader_extension.getBuffers = dri2_wl_get_buffers;
dri2_dpy->dri2_loader_extension.flushFrontBuffer = dri2_wl_flush_front_buffer;
dri2_dpy->dri2_loader_extension.getBuffersWithFormat =
dri2_wl_get_buffers_with_format;
dri2_dpy->extensions[3] = &dri2_dpy->dri2_loader_extension.base;
dri2_dpy->extensions[3] = &dri2_loader_extension.base;
dri2_dpy->extensions[4] = NULL;
} else
dri2_dpy->extensions[3] = NULL;