anv, hasvk: allow using a 3D image as a resolve target
This is allowed by the specification, as the following VUIDs state: VUID-vkCmdResolveImage-srcImage-04446 If dstImage is of type VK_IMAGE_TYPE_3D, then for each element of pRegions, srcSubresource.layerCount must be 1 VUID-vkCmdResolveImage-srcImage-04447 If dstImage is of type VK_IMAGE_TYPE_3D, then for each element of pRegions, dstSubresource.baseArrayLayer must be 0 and dstSubresource.layerCount must be 1 New tests coming for it: dEQP-VK.pipeline.*.multisample.3d.* Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36895>
This commit is contained in:
@@ -2213,7 +2213,9 @@ anv_image_msaa_resolve(struct anv_cmd_buffer *cmd_buffer,
|
||||
|
||||
assert(src_image->vk.image_type == VK_IMAGE_TYPE_2D);
|
||||
assert(src_image->vk.samples > 1);
|
||||
assert(dst_image->vk.image_type == VK_IMAGE_TYPE_2D);
|
||||
assert((dst_image->vk.image_type == VK_IMAGE_TYPE_2D) ||
|
||||
(dst_image->vk.image_type == VK_IMAGE_TYPE_3D &&
|
||||
dst_base_layer == 0 && layer_count == 1));
|
||||
assert(dst_image->vk.samples == 1);
|
||||
|
||||
struct blorp_surf src_surf, dst_surf;
|
||||
|
||||
@@ -1314,7 +1314,9 @@ anv_image_msaa_resolve(struct anv_cmd_buffer *cmd_buffer,
|
||||
|
||||
assert(src_image->vk.image_type == VK_IMAGE_TYPE_2D);
|
||||
assert(src_image->vk.samples > 1);
|
||||
assert(dst_image->vk.image_type == VK_IMAGE_TYPE_2D);
|
||||
assert((dst_image->vk.image_type == VK_IMAGE_TYPE_2D) ||
|
||||
(dst_image->vk.image_type == VK_IMAGE_TYPE_3D &&
|
||||
dst_base_layer == 0 && layer_count == 1));
|
||||
assert(dst_image->vk.samples == 1);
|
||||
|
||||
struct blorp_surf src_surf, dst_surf;
|
||||
|
||||
Reference in New Issue
Block a user