mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-03-02 01:40:54 -05:00
render/egl: add support for EGL_EXT_image_implicit_sync_control
This allows the driver to disable implicit sync logic.
This commit is contained in:
parent
785549bc3e
commit
456f29bd28
2 changed files with 10 additions and 0 deletions
|
|
@ -323,6 +323,9 @@ static bool egl_init_display(struct wlr_egl *egl, EGLDisplay *display) {
|
|||
egl->exts.IMG_context_priority =
|
||||
check_egl_ext(display_exts_str, "EGL_IMG_context_priority");
|
||||
|
||||
egl->exts.EXT_image_implicit_sync_control =
|
||||
check_egl_ext(display_exts_str, "EGL_EXT_image_implicit_sync_control");
|
||||
|
||||
if (check_egl_ext(display_exts_str, "EGL_KHR_fence_sync") &&
|
||||
check_egl_ext(display_exts_str, "EGL_ANDROID_native_fence_sync")) {
|
||||
load_egl_proc(&egl->procs.eglCreateSyncKHR, "eglCreateSyncKHR");
|
||||
|
|
@ -684,6 +687,12 @@ EGLImageKHR wlr_egl_create_image_from_dmabuf(struct wlr_egl *egl,
|
|||
attribs[atti++] = EGL_LINUX_DRM_FOURCC_EXT;
|
||||
attribs[atti++] = attributes->format;
|
||||
|
||||
// TODO: switch on conditionally
|
||||
if (egl->exts.EXT_image_implicit_sync_control) {
|
||||
attribs[atti++] = EGL_IMPORT_SYNC_TYPE_EXT;
|
||||
attribs[atti++] = EGL_IMPORT_EXPLICIT_SYNC_EXT;
|
||||
}
|
||||
|
||||
struct {
|
||||
EGLint fd;
|
||||
EGLint offset;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue