From 7fd3e532792741293ea41959be9cc7922c078dde Mon Sep 17 00:00:00 2001 From: Karol Herbst Date: Fri, 1 Sep 2023 11:57:02 +0200 Subject: [PATCH] asahi: handle images in is_format_supported Some frontends differentiate between textures and images more explicitly than st/mesa. So we might end up with PIPE_BIND_SHADER_IMAGE but not PIPE_BIND_SAMPLER_VIEW in is_format_supported. Signed-off-by: Karol Herbst Reviewed-by: Alyssa Rosenzweig Part-of: --- src/gallium/drivers/asahi/agx_pipe.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/asahi/agx_pipe.c b/src/gallium/drivers/asahi/agx_pipe.c index 8fa5006..1044e9f 100644 --- a/src/gallium/drivers/asahi/agx_pipe.c +++ b/src/gallium/drivers/asahi/agx_pipe.c @@ -1980,7 +1980,8 @@ agx_is_format_supported(struct pipe_screen *pscreen, enum pipe_format format, if (format == PIPE_FORMAT_NONE) return true; - if (usage & (PIPE_BIND_RENDER_TARGET | PIPE_BIND_SAMPLER_VIEW)) { + if (usage & (PIPE_BIND_RENDER_TARGET | PIPE_BIND_SAMPLER_VIEW | + PIPE_BIND_SHADER_IMAGE)) { enum pipe_format tex_format = format; /* Mimic the fixup done in create_sampler_view and u_transfer_helper so we -- 2.7.4