gl-renderer: call supports() automatically in create()
This means compositors don't need to call supports() manually and
create() will just return -1 in the failure case as before. This also
means we can deal with the case of eglGetProcAddress returning
non-NULL but not actually being available at runtime.
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
diff --git a/src/compositor-wayland.c b/src/compositor-wayland.c
index ca747c4..7e59ecd 100644
--- a/src/compositor-wayland.c
+++ b/src/compositor-wayland.c
@@ -1962,12 +1962,7 @@
}
if (!c->use_pixman) {
- if (gl_renderer->supports(&c->base, "wayland") < 0) {
- weston_log("No support for "
- "EGL_{KHR,EXT,MESA}_platform_wayland; "
- "falling back to pixman.\n");
- c->use_pixman = 1;
- } else if (gl_renderer->create(&c->base,
+ if (gl_renderer->create(&c->base,
EGL_PLATFORM_WAYLAND_KHR,
c->parent.wl_display,
gl_renderer->alpha_attribs,