anv_image_from_external(
VkDevice device_h,
const VkImageCreateInfo *base_info,
- const struct VkExternalMemoryImageCreateInfo *create_info,
+ const VkExternalMemoryImageCreateInfo *create_info,
const VkAllocationCallbacks *alloc,
VkImage *out_image_h)
{
#if ANDROID_API_LEVEL >= 26
ANV_FROM_HANDLE(anv_device, device, device_h);
- const struct VkExternalFormatANDROID *ext_info =
+ const VkExternalFormatANDROID *ext_info =
vk_find_struct_const(base_info->pNext, EXTERNAL_FORMAT_ANDROID);
if (ext_info && ext_info->externalFormat != 0) {
VkResult anv_image_from_external(VkDevice device_h,
const VkImageCreateInfo *base_info,
- const struct VkExternalMemoryImageCreateInfo *create_info,
+ const VkExternalMemoryImageCreateInfo *create_info,
const VkAllocationCallbacks *alloc,
VkImage *out_image_h);
VkResult
anv_image_from_external(VkDevice device_h,
const VkImageCreateInfo *base_info,
- const struct VkExternalMemoryImageCreateInfo *create_info,
+ const VkExternalMemoryImageCreateInfo *create_info,
const VkAllocationCallbacks *alloc,
VkImage *out_image_h)
{
* will always write in the immutable sampler regardless of what
* is in the sampler parameter.
*/
- struct VkDescriptorImageInfo info = { };
+ VkDescriptorImageInfo info = { };
anv_descriptor_set_write_image_view(device, set, &info,
VK_DESCRIPTOR_TYPE_SAMPLER,
b, i);
if (result != VK_SUCCESS)
goto fail;
- const struct VkImportAndroidHardwareBufferInfoANDROID import_info = {
+ const VkImportAndroidHardwareBufferInfoANDROID import_info = {
.buffer = mem->ahw,
};
result = anv_import_ahw_memory(_device, mem, &import_info);
const VkPhysicalDeviceExternalImageFormatInfo *external_info = NULL;
VkExternalImageFormatProperties *external_props = NULL;
VkSamplerYcbcrConversionImageFormatProperties *ycbcr_props = NULL;
- struct VkAndroidHardwareBufferUsageANDROID *android_usage = NULL;
+ VkAndroidHardwareBufferUsageANDROID *android_usage = NULL;
VkResult result;
/* Extract input structs */
/* Search for VkExternalFormatANDROID and resolve the format. */
struct anv_format *ext_format = NULL;
- const struct VkExternalFormatANDROID *ext_info =
+ const VkExternalFormatANDROID *ext_info =
vk_find_struct_const(pCreateInfo->pNext, EXTERNAL_FORMAT_ANDROID);
uint64_t format = ext_info ? ext_info->externalFormat : 0;
const VkAllocationCallbacks *pAllocator,
VkImage *pImage)
{
- const struct VkExternalMemoryImageCreateInfo *create_info =
+ const VkExternalMemoryImageCreateInfo *create_info =
vk_find_struct_const(pCreateInfo->pNext, EXTERNAL_MEMORY_IMAGE_CREATE_INFO);
if (create_info && (create_info->handleTypes &
pAllocator, pImage);
bool use_external_format = false;
- const struct VkExternalFormatANDROID *ext_format =
+ const VkExternalFormatANDROID *ext_format =
vk_find_struct_const(pCreateInfo->pNext, EXTERNAL_FORMAT_ANDROID);
/* "If externalFormat is zero, the effect is as if the
/* Check if a conversion info was passed. */
const struct anv_format *conv_format = NULL;
- const struct VkSamplerYcbcrConversionInfo *conv_info =
+ const VkSamplerYcbcrConversionInfo *conv_info =
vk_find_struct_const(pCreateInfo->pNext, SAMPLER_YCBCR_CONVERSION_INFO);
/* If image has an external format, the pNext chain must contain an instance of
for (uint32_t i = 0; i < pCreateInfo->dependencyCount; i++) {
/* Convert to a Dependency2KHR */
- struct VkSubpassDependency2KHR dep2 = {
+ VkSubpassDependency2KHR dep2 = {
.srcSubpass = pCreateInfo->pDependencies[i].srcSubpass,
.dstSubpass = pCreateInfo->pDependencies[i].dstSubpass,
.srcStageMask = pCreateInfo->pDependencies[i].srcStageMask,
enum isl_format
anv_isl_format_for_descriptor_type(VkDescriptorType type);
-static inline struct VkExtent3D
+static inline VkExtent3D
anv_sanitize_image_extent(const VkImageType imageType,
- const struct VkExtent3D imageExtent)
+ const VkExtent3D imageExtent)
{
switch (imageType) {
case VK_IMAGE_TYPE_1D:
}
}
-static inline struct VkOffset3D
+static inline VkOffset3D
anv_sanitize_image_offset(const VkImageType imageType,
- const struct VkOffset3D imageOffset)
+ const VkOffset3D imageOffset)
{
switch (imageType) {
case VK_IMAGE_TYPE_1D:
}
#if GEN_GEN >= 9
case VK_STRUCTURE_TYPE_SAMPLER_REDUCTION_MODE_CREATE_INFO_EXT: {
- struct VkSamplerReductionModeCreateInfoEXT *sampler_reduction =
- (struct VkSamplerReductionModeCreateInfoEXT *) ext;
+ VkSamplerReductionModeCreateInfoEXT *sampler_reduction =
+ (VkSamplerReductionModeCreateInfoEXT *) ext;
sampler_reduction_mode =
vk_to_gen_sampler_reduction_mode[sampler_reduction->reductionMode];
enable_sampler_reduction = true;