weston/libweston/renderer-gl
Pekka Paalanen 8e42af02a6 gl_renderer: introduce gl_renderer_get_egl_config()
In an attempt to pull more of EGLConfig choosing into one place, refactor code
into the new gl_renderer_get_egl_config(). The purpose of this function is to
find an EGL config that not only satisfies the requested attributes and the
pixel formats if given but also makes sure the config is generally compatible
with the single GL context we have.

All this was already checked in gl_renderer_create_window_surface(), but
gl_renderer_create_pbuffer_surface() is still missing it. This patch is
preparation for fixing the pbuffer path.

We explicitly replace visual_id with drm_formats, because that is what they
really are. Only the DRM backend passes in other than NULL/0, and if other
backends start caring about the actual pixel format, drm_format is the lingua
franca.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
2019-10-04 12:17:18 +03:00
..
egl-glue.c gl_renderer: introduce gl_renderer_get_egl_config() 2019-10-04 12:17:18 +03:00
gl-renderer-internal.h gl_renderer: introduce gl_renderer_get_egl_config() 2019-10-04 12:17:18 +03:00
gl-renderer.c gl_renderer: introduce gl_renderer_get_egl_config() 2019-10-04 12:17:18 +03:00
gl-renderer.h gl_renderer: introduce gl_renderer_get_egl_config() 2019-10-04 12:17:18 +03:00
meson.build gl-renderer: move into egl-glue.c 2019-10-04 12:17:18 +03:00