v3dv: don't resolve by averaging samples on depth/stencil resolves

For these we always want to use sample_0, averaging is reserved for
color formats. We were already doing this correctly for depth/stencil
resolved in render passes, but not for those happening through
vkCmdResolveImage.

Fixes some of the issues we have with CTS 1.3.4 in:
dEQP-VK.pipeline.monolithic.multisample.misc.*

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20331>
This commit is contained in:
Iago Toral Quiroga 2022-12-14 12:35:26 +01:00 committed by Marge Bot
parent 6117f855ee
commit 284285376b

View file

@ -623,11 +623,14 @@ emit_resolve_image_layer_per_tile_list(struct v3dv_job *job,
region->dstSubresource.baseArrayLayer + layer_offset :
region->dstOffset.z + layer_offset;
bool is_depth_or_stencil =
region->dstSubresource.aspectMask &
(VK_IMAGE_ASPECT_DEPTH_BIT | VK_IMAGE_ASPECT_STENCIL_BIT);
emit_image_store(job->device, cl, framebuffer, dst,
region->dstSubresource.aspectMask,
dst_layer,
region->dstSubresource.mipLevel,
false, false, true);
false, false, !is_depth_or_stencil);
cl_emit(cl, END_OF_TILE_MARKER, end);