summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2015-12-01 12:52:56 -0800
committerJason Ekstrand <[email protected]>2015-12-03 13:43:53 -0800
commit299f8f1511cfa2bfab77038ba28a90bcfc136a5d (patch)
tree67e52488e99500512716b3f3e33a98b29b9714d7 /src
parent407b8cc5e0e0e0382b7a350480a7654fcb2a164f (diff)
vk/0.210.0: More structure field renaming
Diffstat (limited to 'src')
-rw-r--r--src/vulkan/anv_dump.c6
-rw-r--r--src/vulkan/anv_formats.c4
-rw-r--r--src/vulkan/anv_image.c22
-rw-r--r--src/vulkan/anv_intel.c2
-rw-r--r--src/vulkan/anv_meta.c44
-rw-r--r--src/vulkan/anv_meta_clear.c8
-rw-r--r--src/vulkan/anv_query.c2
-rw-r--r--src/vulkan/anv_wsi_wayland.c2
-rw-r--r--src/vulkan/anv_wsi_x11.c2
-rw-r--r--src/vulkan/gen7_state.c6
-rw-r--r--src/vulkan/gen8_state.c4
11 files changed, 51 insertions, 51 deletions
diff --git a/src/vulkan/anv_dump.c b/src/vulkan/anv_dump.c
index b232f6b206b..80d9fcec88f 100644
--- a/src/vulkan/anv_dump.c
+++ b/src/vulkan/anv_dump.c
@@ -49,7 +49,7 @@ anv_dump_image_to_ppm(struct anv_device *device,
.format = VK_FORMAT_R8G8B8A8_UNORM,
.extent = (VkExtent3D) { extent.width, extent.height, 1 },
.mipLevels = 1,
- .arraySize = 1,
+ .arrayLayers = 1,
.samples = 1,
.tiling = VK_IMAGE_TILING_LINEAR,
.usage = VK_IMAGE_USAGE_TRANSFER_DST_BIT,
@@ -144,9 +144,9 @@ anv_dump_image_to_ppm(struct anv_device *device,
.subresourceRange = (VkImageSubresourceRange) {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = 0,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = 0,
- .arraySize = 1,
+ .layerCount = 1,
},
}});
diff --git a/src/vulkan/anv_formats.c b/src/vulkan/anv_formats.c
index 8afef443696..e79a7105d7d 100644
--- a/src/vulkan/anv_formats.c
+++ b/src/vulkan/anv_formats.c
@@ -432,7 +432,7 @@ VkResult anv_GetPhysicalDeviceImageFormatProperties(
*pImageFormatProperties = (VkImageFormatProperties) {
.maxExtent = maxExtent,
.maxMipLevels = maxMipLevels,
- .maxArraySize = maxArraySize,
+ .maxArrayLayers = maxArraySize,
/* FINISHME: Support multisampling */
.sampleCounts = VK_SAMPLE_COUNT_1_BIT,
@@ -449,7 +449,7 @@ unsupported:
*pImageFormatProperties = (VkImageFormatProperties) {
.maxExtent = { 0, 0, 0 },
.maxMipLevels = 0,
- .maxArraySize = 0,
+ .maxArrayLayers = 0,
.sampleCounts = 0,
.maxResourceSize = 0,
};
diff --git a/src/vulkan/anv_image.c b/src/vulkan/anv_image.c
index 6c39b355958..f52bf456d1e 100644
--- a/src/vulkan/anv_image.c
+++ b/src/vulkan/anv_image.c
@@ -151,7 +151,7 @@ anv_image_make_surface(const struct anv_device *dev,
const VkExtent3D *restrict extent = &create_info->vk_info->extent;
const uint32_t levels = create_info->vk_info->mipLevels;
- const uint32_t array_size = create_info->vk_info->arraySize;
+ const uint32_t array_size = create_info->vk_info->arrayLayers;
const enum isl_tiling tiling = anv_image_choose_tiling(create_info);
const struct anv_tile_info *tile_info =
@@ -303,7 +303,7 @@ anv_image_create(VkDevice _device,
assert(pCreateInfo->sType == VK_STRUCTURE_TYPE_IMAGE_CREATE_INFO);
anv_assert(pCreateInfo->mipLevels > 0);
- anv_assert(pCreateInfo->arraySize > 0);
+ anv_assert(pCreateInfo->arrayLayers > 0);
anv_assert(pCreateInfo->samples == 1);
anv_assert(pCreateInfo->extent.width > 0);
anv_assert(pCreateInfo->extent.height > 0);
@@ -331,7 +331,7 @@ anv_image_create(VkDevice _device,
image->extent = pCreateInfo->extent;
image->format = anv_format_for_vk_format(pCreateInfo->format);
image->levels = pCreateInfo->mipLevels;
- image->array_size = pCreateInfo->arraySize;
+ image->array_size = pCreateInfo->arrayLayers;
image->usage = anv_image_get_full_usage(pCreateInfo);
image->surface_type = surf_type;
@@ -487,17 +487,17 @@ anv_validate_CreateImageView(VkDevice _device,
/* Validate subresource. */
assert(subresource->aspectMask != 0);
- assert(subresource->mipLevels > 0);
- assert(subresource->arraySize > 0);
+ assert(subresource->levelCount > 0);
+ assert(subresource->layerCount > 0);
assert(subresource->baseMipLevel < image->levels);
- assert(subresource->baseMipLevel + subresource->mipLevels <= image->levels);
+ assert(subresource->baseMipLevel + subresource->levelCount <= image->levels);
assert(subresource->baseArrayLayer < image->array_size);
- assert(subresource->baseArrayLayer + subresource->arraySize <= image->array_size);
+ assert(subresource->baseArrayLayer + subresource->layerCount <= image->array_size);
assert(pView);
if (view_info->is_cube) {
assert(subresource->baseArrayLayer % 6 == 0);
- assert(subresource->arraySize % 6 == 0);
+ assert(subresource->layerCount % 6 == 0);
}
const VkImageAspectFlags ds_flags = VK_IMAGE_ASPECT_DEPTH_BIT
@@ -543,7 +543,7 @@ anv_image_view_init(struct anv_image_view *iview,
ANV_FROM_HANDLE(anv_image, image, pCreateInfo->image);
const VkImageSubresourceRange *range = &pCreateInfo->subresourceRange;
- assert(range->arraySize > 0);
+ assert(range->layerCount > 0);
assert(range->baseMipLevel < image->levels);
assert(image->usage & (VK_IMAGE_USAGE_SAMPLED_BIT |
VK_IMAGE_USAGE_STORAGE_BIT |
@@ -555,10 +555,10 @@ anv_image_view_init(struct anv_image_view *iview,
unreachable("bad VkImageType");
case VK_IMAGE_TYPE_1D:
case VK_IMAGE_TYPE_2D:
- assert(range->baseArrayLayer + range->arraySize - 1 <= image->array_size);
+ assert(range->baseArrayLayer + range->layerCount - 1 <= image->array_size);
break;
case VK_IMAGE_TYPE_3D:
- assert(range->baseArrayLayer + range->arraySize - 1
+ assert(range->baseArrayLayer + range->layerCount - 1
<= anv_minify(image->extent.depth, range->baseMipLevel));
break;
}
diff --git a/src/vulkan/anv_intel.c b/src/vulkan/anv_intel.c
index 48ac183ad79..5507bf2d5cb 100644
--- a/src/vulkan/anv_intel.c
+++ b/src/vulkan/anv_intel.c
@@ -78,7 +78,7 @@ VkResult anv_CreateDmaBufImageINTEL(
.format = pCreateInfo->format,
.extent = pCreateInfo->extent,
.mipLevels = 1,
- .arraySize = 1,
+ .arrayLayers = 1,
.samples = 1,
/* FIXME: Need a way to use X tiling to allow scanout */
.tiling = VK_IMAGE_TILING_OPTIMAL,
diff --git a/src/vulkan/anv_meta.c b/src/vulkan/anv_meta.c
index a2626a0f63e..419667a9f30 100644
--- a/src/vulkan/anv_meta.c
+++ b/src/vulkan/anv_meta.c
@@ -674,7 +674,7 @@ do_buffer_copy(struct anv_cmd_buffer *cmd_buffer,
.depth = 1,
},
.mipLevels = 1,
- .arraySize = 1,
+ .arrayLayers = 1,
.samples = 1,
.tiling = VK_IMAGE_TILING_LINEAR,
.usage = 0,
@@ -707,9 +707,9 @@ do_buffer_copy(struct anv_cmd_buffer *cmd_buffer,
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = 0,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = 0,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
@@ -724,9 +724,9 @@ do_buffer_copy(struct anv_cmd_buffer *cmd_buffer,
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = 0,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = 0,
- .arraySize = 1,
+ .layerCount = 1,
},
},
cmd_buffer);
@@ -855,9 +855,9 @@ void anv_CmdCopyImage(
.subresourceRange = {
.aspectMask = pRegions[r].srcSubresource.aspectMask,
.baseMipLevel = pRegions[r].srcSubresource.mipLevel,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = pRegions[r].srcSubresource.baseArrayLayer,
- .arraySize = pRegions[r].dstSubresource.layerCount,
+ .layerCount = pRegions[r].dstSubresource.layerCount,
},
},
cmd_buffer);
@@ -899,9 +899,9 @@ void anv_CmdCopyImage(
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = pRegions[r].dstSubresource.mipLevel,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = dest_base_array_slice + slice,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
@@ -955,9 +955,9 @@ void anv_CmdBlitImage(
.subresourceRange = {
.aspectMask = pRegions[r].srcSubresource.aspectMask,
.baseMipLevel = pRegions[r].srcSubresource.mipLevel,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = pRegions[r].srcSubresource.baseArrayLayer,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
@@ -989,9 +989,9 @@ void anv_CmdBlitImage(
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = pRegions[r].dstSubresource.mipLevel,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = dest_array_slice,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
@@ -1032,7 +1032,7 @@ make_image_for_buffer(VkDevice vk_device, VkBuffer vk_buffer, VkFormat format,
.format = format,
.extent = extent,
.mipLevels = 1,
- .arraySize = 1,
+ .arrayLayers = 1,
.samples = 1,
.tiling = VK_IMAGE_TILING_LINEAR,
.usage = usage,
@@ -1106,9 +1106,9 @@ void anv_CmdCopyBufferToImage(
.subresourceRange = {
.aspectMask = proxy_aspect,
.baseMipLevel = 0,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = 0,
- .arraySize = 1,
+ .layerCount = 1,
},
},
cmd_buffer);
@@ -1123,9 +1123,9 @@ void anv_CmdCopyBufferToImage(
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = pRegions[r].imageSubresource.mipLevel,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = dest_base_array_slice + slice,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
@@ -1194,9 +1194,9 @@ void anv_CmdCopyImageToBuffer(
.subresourceRange = {
.aspectMask = pRegions[r].imageSubresource.aspectMask,
.baseMipLevel = pRegions[r].imageSubresource.mipLevel,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = pRegions[r].imageSubresource.baseArrayLayer,
- .arraySize = pRegions[r].imageSubresource.layerCount,
+ .layerCount = pRegions[r].imageSubresource.layerCount,
},
},
cmd_buffer);
@@ -1234,9 +1234,9 @@ void anv_CmdCopyImageToBuffer(
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = 0,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = 0,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
diff --git a/src/vulkan/anv_meta_clear.c b/src/vulkan/anv_meta_clear.c
index 27c6a291967..0531eccad9b 100644
--- a/src/vulkan/anv_meta_clear.c
+++ b/src/vulkan/anv_meta_clear.c
@@ -690,8 +690,8 @@ void anv_CmdClearColorImage(
meta_clear_begin(&saved_state, cmd_buffer);
for (uint32_t r = 0; r < rangeCount; r++) {
- for (uint32_t l = 0; l < pRanges[r].mipLevels; l++) {
- for (uint32_t s = 0; s < pRanges[r].arraySize; s++) {
+ for (uint32_t l = 0; l < pRanges[r].levelCount; l++) {
+ for (uint32_t s = 0; s < pRanges[r].layerCount; s++) {
struct anv_image_view iview;
anv_image_view_init(&iview, cmd_buffer->device,
&(VkImageViewCreateInfo) {
@@ -702,9 +702,9 @@ void anv_CmdClearColorImage(
.subresourceRange = {
.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT,
.baseMipLevel = pRanges[r].baseMipLevel + l,
- .mipLevels = 1,
+ .levelCount = 1,
.baseArrayLayer = pRanges[r].baseArrayLayer + s,
- .arraySize = 1
+ .layerCount = 1
},
},
cmd_buffer);
diff --git a/src/vulkan/anv_query.c b/src/vulkan/anv_query.c
index 8891aa02d76..7aa54363aee 100644
--- a/src/vulkan/anv_query.c
+++ b/src/vulkan/anv_query.c
@@ -55,7 +55,7 @@ VkResult anv_CreateQueryPool(
if (pool == NULL)
return vk_error(VK_ERROR_OUT_OF_HOST_MEMORY);
- size = pCreateInfo->slots * sizeof(struct anv_query_pool_slot);
+ size = pCreateInfo->entryCount * sizeof(struct anv_query_pool_slot);
result = anv_bo_init_new(&pool->bo, device, size);
if (result != VK_SUCCESS)
goto fail;
diff --git a/src/vulkan/anv_wsi_wayland.c b/src/vulkan/anv_wsi_wayland.c
index d226c8d06c1..581c8a0e90c 100644
--- a/src/vulkan/anv_wsi_wayland.c
+++ b/src/vulkan/anv_wsi_wayland.c
@@ -561,7 +561,7 @@ wsi_wl_image_init(struct wsi_wl_swapchain *chain, struct wsi_wl_image *image)
.depth = 1
},
.mipLevels = 1,
- .arraySize = 1,
+ .arrayLayers = 1,
.samples = 1,
/* FIXME: Need a way to use X tiling to allow scanout */
.tiling = VK_IMAGE_TILING_OPTIMAL,
diff --git a/src/vulkan/anv_wsi_x11.c b/src/vulkan/anv_wsi_x11.c
index 4beffce3ce5..1ab31c52573 100644
--- a/src/vulkan/anv_wsi_x11.c
+++ b/src/vulkan/anv_wsi_x11.c
@@ -313,7 +313,7 @@ x11_create_swapchain(struct anv_wsi_implementation *impl,
.depth = 1
},
.mipLevels = 1,
- .arraySize = 1,
+ .arrayLayers = 1,
.samples = 1,
/* FIXME: Need a way to use X tiling to allow scanout */
.tiling = VK_IMAGE_TILING_OPTIMAL,
diff --git a/src/vulkan/gen7_state.c b/src/vulkan/gen7_state.c
index a30de348732..e4cf552f90d 100644
--- a/src/vulkan/gen7_state.c
+++ b/src/vulkan/gen7_state.c
@@ -231,8 +231,8 @@ genX(image_view_init)(struct anv_image_view *iview,
};
uint32_t depth = 1;
- if (range->arraySize > 1) {
- depth = range->arraySize;
+ if (range->layerCount > 1) {
+ depth = range->layerCount;
} else if (image->extent.depth > 1) {
depth = image->extent.depth;
}
@@ -300,7 +300,7 @@ genX(image_view_init)(struct anv_image_view *iview,
* sampler engine is [SurfaceMinLOD, SurfaceMinLOD + MIPCountLOD].
*/
surface_state.SurfaceMinLOD = range->baseMipLevel;
- surface_state.MIPCountLOD = range->mipLevels - 1;
+ surface_state.MIPCountLOD = range->levelCount - 1;
GENX(RENDER_SURFACE_STATE_pack)(NULL, iview->nonrt_surface_state.map,
&surface_state);
diff --git a/src/vulkan/gen8_state.c b/src/vulkan/gen8_state.c
index 092e1ae7822..02394dc6f61 100644
--- a/src/vulkan/gen8_state.c
+++ b/src/vulkan/gen8_state.c
@@ -145,7 +145,7 @@ genX(image_view_init)(struct anv_image_view *iview,
* example, if Minimum Array Element is set to 1024 on a 2D surface,
* the range of this field is reduced to [0,1023].
*/
- depth = range->arraySize;
+ depth = range->layerCount;
/* From the Broadwell PRM >> RENDER_SURFACE_STATE::RenderTargetViewExtent:
*
@@ -242,7 +242,7 @@ genX(image_view_init)(struct anv_image_view *iview,
* sampler engine is [SurfaceMinLOD, SurfaceMinLOD + MIPCountLOD].
*/
surface_state.SurfaceMinLOD = range->baseMipLevel;
- surface_state.MIPCountLOD = range->mipLevels - 1;
+ surface_state.MIPCountLOD = range->levelCount - 1;
GENX(RENDER_SURFACE_STATE_pack)(NULL, iview->nonrt_surface_state.map,
&surface_state);