aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Blumenkrantz <[email protected]>2020-06-14 00:30:55 -0400
committerMarge Bot <[email protected]>2020-07-14 12:57:22 +0000
commit582669f07e7d0ee4ef61d2e487f886be9e8e7890 (patch)
treea3cdc7320b06b2dc809941674cd8c3cd2c1b4e9b
parentab78831baa6329ad1b43dfd0203e6be508e4194d (diff)
zink: block vkCmdBlitImage usage for multi sampled blits
this is prohibited by spec Reviewed-by: Erik Faye-Lund <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5888>
-rw-r--r--src/gallium/drivers/zink/zink_blit.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/zink/zink_blit.c b/src/gallium/drivers/zink/zink_blit.c
index 6dd3caaece1..2fdc7d582be 100644
--- a/src/gallium/drivers/zink/zink_blit.c
+++ b/src/gallium/drivers/zink/zink_blit.c
@@ -80,6 +80,10 @@ blit_native(struct zink_context *ctx, const struct pipe_blit_info *info)
info->dst.format != info->src.format)
return false;
+ /* vkCmdBlitImage must not be used for multisampled source or destination images. */
+ if (info->src.resource->nr_samples > 1 || info->dst.resource->nr_samples > 1)
+ return false;
+
struct zink_resource *src = zink_resource(info->src.resource);
struct zink_resource *dst = zink_resource(info->dst.resource);