gl-renderer: remove EGLConfig attributes from API

Now that all backends pass in a list of acceptable DRM formats, that is used to
determine if the EGLConfig has an alpha channel or not. Therefore the
opaque_attribs and alpha_attribs are now useless, and we can remove the whole
config_attribs argument from the API.

gl_renderer_get_egl_config() uses an internal attrib list that matches at least
the union of the opaque_attribs and alpha_attribs matches.

Overall, behaviour should remain unchanged.

The new attribute array becomes variable in the future, so it is left
non-const.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
This commit is contained in:
Pekka Paalanen
2019-09-30 15:43:07 +03:00
parent 9ddb3bc315
commit 7cb7a6781f
7 changed files with 10 additions and 44 deletions
-2
View File
@@ -747,7 +747,6 @@ drm_backend_create_gl_renderer(struct drm_backend *b)
if (gl_renderer->display_create(b->compositor,
EGL_PLATFORM_GBM_KHR,
(void *)b->gbm,
gl_renderer->opaque_attribs,
format,
n_formats) < 0) {
return -1;
@@ -1393,7 +1392,6 @@ drm_output_init_egl(struct drm_output *output, struct drm_backend *b)
if (gl_renderer->output_window_create(&output->base,
(EGLNativeWindowType)output->gbm_surface,
output->gbm_surface,
gl_renderer->opaque_attribs,
format,
n_formats) < 0) {
weston_log("failed to create gl renderer output state\n");