vkGetPhysicalDeviceImageFormatProperties2(3)

# vkGetPhysicalDeviceImageFormatProperties2(3) Manual Page

## Name

vkGetPhysicalDeviceImageFormatProperties2 - Lists physical device's image format capabilities

Loading… please wait.

## C Specification

To query additional capabilities specific to image types, call:

    // Provided by VK_VERSION_1_1
    VkResult vkGetPhysicalDeviceImageFormatProperties2(
        VkPhysicalDevice                            physicalDevice,
        const VkPhysicalDeviceImageFormatInfo2*     pImageFormatInfo,
        VkImageFormatProperties2*                   pImageFormatProperties);

or the equivalent command

    // Provided by VK_KHR_get_physical_device_properties2
    VkResult vkGetPhysicalDeviceImageFormatProperties2KHR(
        VkPhysicalDevice                            physicalDevice,
        const VkPhysicalDeviceImageFormatInfo2*     pImageFormatInfo,
        VkImageFormatProperties2*                   pImageFormatProperties);

## Parameters

- `physicalDevice` is the physical device from which to query the image capabilities.

- `pImageFormatInfo` is a pointer to a VkPhysicalDeviceImageFormatInfo2 structure describing the parameters that would be consumed by vkCreateImage.

- `pImageFormatProperties` is a pointer to a VkImageFormatProperties2 structure in which capabilities are returned.

## Description

`vkGetPhysicalDeviceImageFormatProperties2` behaves similarly to vkGetPhysicalDeviceImageFormatProperties, with the ability to return extended information in a `pNext` chain of output structures.

If the `pNext` chain of `pImageFormatInfo` includes a VkVideoProfileListInfoKHR structure with a `profileCount` member greater than `0`, then this command returns format capabilities specific to image types used in conjunction with the specified video profiles. In this case, this command will return one of the video-profile-specific error codes if any of the profiles specified via VkVideoProfileListInfoKHR::`pProfiles` are not supported. Furthermore, if VkPhysicalDeviceImageFormatInfo2::`usage` includes any image usage flag not supported by the specified video profiles, then this command returns `VK_ERROR_IMAGE_USAGE_NOT_SUPPORTED_KHR`.

Valid Usage

- VUID-vkGetPhysicalDeviceImageFormatProperties2-pNext-01868
  If the `pNext` chain of `pImageFormatProperties` includes a VkAndroidHardwareBufferUsageANDROID structure, the `pNext` chain of `pImageFormatInfo` must include a VkPhysicalDeviceExternalImageFormatInfo structure with `handleType` set to `VK_EXTERNAL_MEMORY_HANDLE_TYPE_ANDROID_HARDWARE_BUFFER_BIT_ANDROID`

- VUID-vkGetPhysicalDeviceImageFormatProperties2-pNext-09004
  If the `pNext` chain of `pImageFormatProperties` includes a VkHostImageCopyDevicePerformanceQueryEXT structure, `pImageFormatInfo->usage` must contain `VK_IMAGE_USAGE_HOST_TRANSFER_BIT_EXT`

Valid Usage (Implicit)

- VUID-vkGetPhysicalDeviceImageFormatProperties2-physicalDevice-parameter
  `physicalDevice` must be a valid VkPhysicalDevice handle

- VUID-vkGetPhysicalDeviceImageFormatProperties2-pImageFormatInfo-parameter
  `pImageFormatInfo` must be a valid pointer to a valid VkPhysicalDeviceImageFormatInfo2 structure

- VUID-vkGetPhysicalDeviceImageFormatProperties2-pImageFormatProperties-parameter
  `pImageFormatProperties` must be a valid pointer to a VkImageFormatProperties2 structure

Return Codes

On success, this command returns

  - `VK_SUCCESS`

On failure, this command returns

  - `VK_ERROR_OUT_OF_HOST_MEMORY`

  - `VK_ERROR_OUT_OF_DEVICE_MEMORY`

  - `VK_ERROR_FORMAT_NOT_SUPPORTED`

  - `VK_ERROR_IMAGE_USAGE_NOT_SUPPORTED_KHR`

  - `VK_ERROR_VIDEO_PROFILE_OPERATION_NOT_SUPPORTED_KHR`

  - `VK_ERROR_VIDEO_PROFILE_FORMAT_NOT_SUPPORTED_KHR`

  - `VK_ERROR_VIDEO_PICTURE_LAYOUT_NOT_SUPPORTED_KHR`

  - `VK_ERROR_VIDEO_PROFILE_CODEC_NOT_SUPPORTED_KHR`

## See Also

VK_VERSION_1_1, VkImageFormatProperties2, VkPhysicalDevice, VkPhysicalDeviceImageFormatInfo2

## Document Notes

For more information, see the Vulkan Specification

This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.

## Copyright

Copyright 2014-2024 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0