vk: Drop anv_attachment_view::extent
authorChad Versace <chad.versace@intel.com>
Mon, 5 Oct 2015 23:58:25 +0000 (16:58 -0700)
committerChad Versace <chad.versace@intel.com>
Tue, 6 Oct 2015 00:46:04 +0000 (17:46 -0700)
It's duplicated by anv_attachment_view::image_view::extent.

src/vulkan/anv_meta.c
src/vulkan/anv_private.h
src/vulkan/gen7_state.c
src/vulkan/gen8_state.c

index 1574830e0b8fd98c2009f25403c6bd3a80cdf558..085acc7a31800e461f929b3f6178cd3bb71b892f 100644 (file)
@@ -842,8 +842,8 @@ meta_emit_blit(struct anv_cmd_buffer *cmd_buffer,
                .layout = VK_IMAGE_LAYOUT_GENERAL
             }
          },
-         .width = dest_aview->extent.width,
-         .height = dest_aview->extent.height,
+         .width = dest_iview->extent.width,
+         .height = dest_iview->extent.height,
          .layers = 1
       }, &fb);
 
@@ -1574,8 +1574,8 @@ void anv_CmdClearColorImage(
                         .layout = VK_IMAGE_LAYOUT_GENERAL
                      }
                   },
-                  .width = aview->extent.width,
-                  .height = aview->extent.height,
+                  .width = iview->extent.width,
+                  .height = iview->extent.height,
                   .layers = 1
                }, &fb);
 
@@ -1622,8 +1622,8 @@ void anv_CmdClearColorImage(
                   .renderArea = {
                      .offset = { 0, 0, },
                      .extent = {
-                        .width = aview->extent.width,
-                        .height = aview->extent.height,
+                        .width = iview->extent.width,
+                        .height = iview->extent.height,
                      },
                   },
                   .renderPass = pass,
index 8c4c9efdc6fd85ff20c2fd4d8fb2c0309d6c3cf2..b290fcc75b78bd80be3b12fb5d9fe147524a4f10 100644 (file)
@@ -1258,7 +1258,6 @@ enum anv_attachment_view_type {
 
 struct anv_attachment_view {
    enum anv_attachment_view_type attachment_type;
-   VkExtent3D extent;
 };
 
 struct anv_color_attachment_view {
index 5031db5edea46537af0b83d4c549a3f22fda0a98..d65c1a373f0cb2114509c1b2531d835e7de6396a 100644 (file)
@@ -381,7 +381,7 @@ gen7_color_attachment_view_init(struct anv_color_attachment_view *cview,
    iview->offset = image->offset + surface->offset;
    iview->format = anv_format_for_vk_format(pCreateInfo->format);
 
-   aview->extent = (VkExtent3D) {
+   iview->extent = (VkExtent3D) {
       .width = anv_minify(image->extent.width, pCreateInfo->mipLevel),
       .height = anv_minify(image->extent.height, pCreateInfo->mipLevel),
       .depth = anv_minify(image->extent.depth, pCreateInfo->mipLevel),
index 2b820a3177d78cc95785724103a5627421ca2e7c..8e9b43cab052313174aafea10b63ca3002859614 100644 (file)
@@ -307,7 +307,7 @@ gen8_color_attachment_view_init(struct anv_color_attachment_view *cview,
    iview->offset = image->offset + surface->offset;
    iview->format = anv_format_for_vk_format(pCreateInfo->format);
 
-   aview->extent = (VkExtent3D) {
+   iview->extent = (VkExtent3D) {
       .width = anv_minify(image->extent.width, pCreateInfo->mipLevel),
       .height = anv_minify(image->extent.height, pCreateInfo->mipLevel),
       .depth = anv_minify(image->extent.depth, pCreateInfo->mipLevel),
@@ -346,7 +346,7 @@ gen8_color_attachment_view_init(struct anv_color_attachment_view *cview,
        *    indicates the extent of the accessible 'R' coordinates minus 1 on
        *    the LOD currently being rendered to.
        */
-      rt_view_extent = aview->extent.depth;
+      rt_view_extent = iview->extent.depth;
       break;
    default:
       unreachable(!"bad VkImageType");