vulkan/wsi: fix force_bgra8_unorm_first

fixes: 7c16a1ae vulkan/wsi: Add a driconf option to force WSI to advertise BGRA8_UNORM first

Signed-off-by: Robert Beckett <bob.beckett@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23991>
This commit is contained in:
Robert Beckett
2023-07-04 14:16:18 +01:00
committed by Marge Bot
parent 224ff11617
commit 9c096e23c0
+1 -1
View File
@@ -928,7 +928,7 @@ wsi_wl_display_init(struct wsi_wayland *wsi_wl,
/* Find BGRA8_UNORM in the list and swap it to the first position if we
* can find it. Some apps get confused if SRGB is first in the list.
*/
struct wsi_wl_format *first_fmt = u_vector_head(&display->formats);
struct wsi_wl_format *first_fmt = u_vector_tail(&display->formats);
struct wsi_wl_format *f, tmp_fmt;
f = find_format(&display->formats, VK_FORMAT_B8G8R8A8_UNORM);
if (f) {