To enumerate the supported output, input and Dpb image formats for a specific codec operation and video profile, call:
// Provided by VK_KHR_video_queue VkResult vkGetPhysicalDeviceVideoFormatPropertiesKHR( VkPhysicalDevice physicalDevice, const VkPhysicalDeviceVideoFormatInfoKHR* pVideoFormatInfo, uint32_t* pVideoFormatPropertyCount, VkVideoFormatPropertiesKHR* pVideoFormatProperties);
physicalDeviceis the physical device being queried.
pVideoFormatInfois a pointer to an instance of VkPhysicalDeviceVideoFormatInfoKHR, the input structure.
pVideoFormatPropertyCountis a pointer to an integer related to the number of video format properties available or queried, as described below.
pVideoFormatPropertiesis a pointer to an array of VkVideoFormatPropertiesKHR, where the implementation would populate the supported formats.
NULL, then the number of video format
properties supported for the given
physicalDevice is returned in
pVideoFormatPropertyCount must point to a variable set by
the user to the number of elements in the
array, and on return the variable is overwritten with the number of values
actually written to
If the value of
pVideoFormatPropertyCount is less than the number of
video format properties supported, at most
values will be written to
VK_INCOMPLETE will be returned instead of
indicate that not all the available values were returned.
For most use cases, only decode or encode related usage flags are going to be specified. For a use case such as transcode, if the image were to be shared between decode and encode session(s), then both decode and encode related usage flags can be set.
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.