mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-01 05:58:05 +02:00
wl/shm: don't fetch formats if not requested.
This aligns the code with the drm format code Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Simon Ser <contact@emersion.fr> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11959>
This commit is contained in:
parent
a7f1ebda2c
commit
3e228bc8a9
1 changed files with 3 additions and 0 deletions
|
|
@ -418,6 +418,9 @@ static void
|
|||
shm_handle_format(void *data, struct wl_shm *shm, uint32_t format)
|
||||
{
|
||||
struct wsi_wl_display *display = data;
|
||||
if (display->swrast.formats.element_size == 0)
|
||||
return;
|
||||
|
||||
wsi_wl_display_add_wl_shm_format(display, &display->swrast.formats, format);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue