Mesa (main): egl/wayland: manually swap backbuffer when using zink
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Jun 3 19:05:28 UTC 2022
Module: Mesa
Branch: main
Commit: f67bd8adfab7eac1bd83ee5d3cc90d6dce76fbf3
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=f67bd8adfab7eac1bd83ee5d3cc90d6dce76fbf3
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Wed Jun 1 10:47:27 2022 -0400
egl/wayland: manually swap backbuffer when using zink
this would usually occur through dri2_wl_swrast_commit_backbuffer(),
but zink triggers this functionality using vulkan wsi, which fails to
perform these updates as expected
cc: mesa-stable
Reviewed-by: Adam Jackson <ajax at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16814>
---
src/egl/drivers/dri2/platform_wayland.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/egl/drivers/dri2/platform_wayland.c b/src/egl/drivers/dri2/platform_wayland.c
index 01aff28240c..2fa55d9820a 100644
--- a/src/egl/drivers/dri2/platform_wayland.c
+++ b/src/egl/drivers/dri2/platform_wayland.c
@@ -2579,6 +2579,10 @@ dri2_wl_swrast_swap_buffers(_EGLDisplay *disp, _EGLSurface *draw)
return _eglError(EGL_BAD_NATIVE_WINDOW, "dri2_swap_buffers");
dri2_dpy->core->swapBuffers(dri2_surf->dri_drawable);
+ if (disp->Options.Zink) {
+ dri2_surf->current = dri2_surf->back;
+ dri2_surf->back = NULL;
+ }
return EGL_TRUE;
}
More information about the mesa-commit
mailing list