zink: Add an assert for not seeing any more MSAA image-to-buffer copies.
Now that transfer_map gets MSAA handled by the helper, we shouldn't have to worry about this any more. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20523>
This commit is contained in:
@@ -4419,7 +4419,8 @@ zink_copy_image_buffer(struct zink_context *ctx, struct zink_resource *dst, stru
|
|||||||
int aspect = 1 << u_bit_scan(&aspects);
|
int aspect = 1 << u_bit_scan(&aspects);
|
||||||
region.imageSubresource.aspectMask = aspect;
|
region.imageSubresource.aspectMask = aspect;
|
||||||
|
|
||||||
/* this may or may not work with multisampled depth/stencil buffers depending on the driver implementation:
|
/* MSAA transfers should have already been handled by U_TRANSFER_HELPER_MSAA_MAP, since
|
||||||
|
* there's no way to resolve using this interface:
|
||||||
*
|
*
|
||||||
* srcImage must have a sample count equal to VK_SAMPLE_COUNT_1_BIT
|
* srcImage must have a sample count equal to VK_SAMPLE_COUNT_1_BIT
|
||||||
* - vkCmdCopyImageToBuffer spec
|
* - vkCmdCopyImageToBuffer spec
|
||||||
@@ -4427,6 +4428,7 @@ zink_copy_image_buffer(struct zink_context *ctx, struct zink_resource *dst, stru
|
|||||||
* dstImage must have a sample count equal to VK_SAMPLE_COUNT_1_BIT
|
* dstImage must have a sample count equal to VK_SAMPLE_COUNT_1_BIT
|
||||||
* - vkCmdCopyBufferToImage spec
|
* - vkCmdCopyBufferToImage spec
|
||||||
*/
|
*/
|
||||||
|
assert(img->base.b.nr_samples <= 1);
|
||||||
if (buf2img)
|
if (buf2img)
|
||||||
VKCTX(CmdCopyBufferToImage)(cmdbuf, buf->obj->buffer, img->obj->image, img->layout, 1, ®ion);
|
VKCTX(CmdCopyBufferToImage)(cmdbuf, buf->obj->buffer, img->obj->image, img->layout, 1, ®ion);
|
||||||
else
|
else
|
||||||
|
Reference in New Issue
Block a user