wayland/dma-buf: Enable modifiers by default on non-native backend
If the used EGL backend supports it. In practice this should currently only affect the nested backend. Enabling modifiers can help with app development. An example is `weston-simple-dmabuf-v4l`, which requires the linear modifier to be available. Note that Weston behaves similar already. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2972>
This commit is contained in:
parent
04fa926eea
commit
754a1a1ce6
@ -157,7 +157,20 @@ should_send_modifiers (MetaBackend *backend)
|
|||||||
MetaGpuKms *gpu_kms;
|
MetaGpuKms *gpu_kms;
|
||||||
|
|
||||||
if (!META_IS_BACKEND_NATIVE (backend))
|
if (!META_IS_BACKEND_NATIVE (backend))
|
||||||
return FALSE;
|
{
|
||||||
|
MetaEgl *egl = meta_backend_get_egl (backend);
|
||||||
|
ClutterBackend *clutter_backend =
|
||||||
|
meta_backend_get_clutter_backend (backend);
|
||||||
|
CoglContext *cogl_context =
|
||||||
|
clutter_backend_get_cogl_context (clutter_backend);
|
||||||
|
EGLDisplay egl_display = cogl_egl_context_get_egl_display (cogl_context);
|
||||||
|
|
||||||
|
return meta_egl_has_extensions (egl,
|
||||||
|
egl_display,
|
||||||
|
NULL,
|
||||||
|
"EGL_EXT_image_dma_buf_import_modifiers",
|
||||||
|
NULL);
|
||||||
|
}
|
||||||
|
|
||||||
renderer_native = META_RENDERER_NATIVE (meta_backend_get_renderer (backend));
|
renderer_native = META_RENDERER_NATIVE (meta_backend_get_renderer (backend));
|
||||||
gpu_kms = meta_renderer_native_get_primary_gpu (renderer_native);
|
gpu_kms = meta_renderer_native_get_primary_gpu (renderer_native);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user