nvk: Use the new NIL helper for image level extents for copies
authorFaith Ekstrand <faith.ekstrand@collabora.com>
Tue, 1 Aug 2023 23:26:43 +0000 (18:26 -0500)
committerMarge Bot <emma+marge@anholt.net>
Fri, 4 Aug 2023 21:32:07 +0000 (21:32 +0000)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>

src/nouveau/vulkan/nvk_cmd_copy.c

index c9e8e0c..732b84d 100644 (file)
@@ -72,10 +72,8 @@ nouveau_copy_rect_image(
    VkOffset3D offset_px,
    const VkImageSubresourceLayers *sub_res)
 {
-   const VkExtent3D lvl_extent_px =
-      vk_image_mip_level_extent(&img->vk, sub_res->mipLevel);
    const struct nil_extent4d lvl_extent4d_px =
-      vk_to_nil_extent(lvl_extent_px, img->vk.array_layers);
+      nil_image_level_extent_px(&plane->nil, sub_res->mipLevel);
 
    offset_px = vk_image_sanitize_offset(&img->vk, offset_px);
    const struct nil_offset4d offset4d_px =