[Mesa-dev] [RFC PATCH 12/13] RFC: anv: Drop unused anv_image_create()
Chad Versace
chadversary at chromium.org
Mon Mar 6 20:40:21 UTC 2017
---
src/intel/vulkan/anv_image.c | 26 ++++++--------------------
src/intel/vulkan/anv_private.h | 5 -----
2 files changed, 6 insertions(+), 25 deletions(-)
diff --git a/src/intel/vulkan/anv_image.c b/src/intel/vulkan/anv_image.c
index 60b33fba2ae..998b0b43391 100644
--- a/src/intel/vulkan/anv_image.c
+++ b/src/intel/vulkan/anv_image.c
@@ -380,13 +380,13 @@ make_main_surface(const struct anv_device *dev,
}
VkResult
-anv_image_create(VkDevice _device,
- const struct anv_image_create_info *anv_info,
- const VkAllocationCallbacks* alloc,
- VkImage *pImage)
+anv_CreateImage(VkDevice _device,
+ const VkImageCreateInfo *base_info,
+ const VkAllocationCallbacks* alloc,
+ VkImage *pImage)
{
ANV_FROM_HANDLE(anv_device, device, _device);
- const VkImageCreateInfo *base_info = anv_info->vk_info;
+ const struct anv_image_create_info anv_info = { .vk_info = base_info };
const VkImportImageDmaBufInfoMESAX *import_dma_buf_info = NULL;
const VkExportImageDmaBufInfoMESAX *export_dma_buf_info = NULL;
VkExternalMemoryHandleTypeFlagsKHX handle_types = 0;
@@ -444,7 +444,7 @@ anv_image_create(VkDevice _device,
uint32_t b;
for_each_bit(b, image->aspects) {
VkImageAspectFlagBits aspect = 1 << b;
- make_main_surface(device, anv_info, import_dma_buf_info,
+ make_main_surface(device, &anv_info, import_dma_buf_info,
export_dma_buf_info, aspect, handle_types, image);
make_aux_surface_maybe(device, base_info, aspect, handle_types, image);
}
@@ -454,20 +454,6 @@ anv_image_create(VkDevice _device,
return VK_SUCCESS;
}
-VkResult
-anv_CreateImage(VkDevice device,
- const VkImageCreateInfo *pCreateInfo,
- const VkAllocationCallbacks *pAllocator,
- VkImage *pImage)
-{
- return anv_image_create(device,
- &(struct anv_image_create_info) {
- .vk_info = pCreateInfo,
- },
- pAllocator,
- pImage);
-}
-
void
anv_DestroyImage(VkDevice _device, VkImage _image,
const VkAllocationCallbacks *pAllocator)
diff --git a/src/intel/vulkan/anv_private.h b/src/intel/vulkan/anv_private.h
index 103a9d68a9e..2f62ec50c5b 100644
--- a/src/intel/vulkan/anv_private.h
+++ b/src/intel/vulkan/anv_private.h
@@ -1869,11 +1869,6 @@ struct anv_image_create_info {
uint32_t stride;
};
-VkResult anv_image_create(VkDevice _device,
- const struct anv_image_create_info *info,
- const VkAllocationCallbacks* alloc,
- VkImage *pImage);
-
const struct anv_surface *
anv_image_get_surface_for_aspect_mask(const struct anv_image *image,
VkImageAspectFlags aspect_mask);
--
2.12.0
More information about the mesa-dev
mailing list