vkGetPhysicalDeviceVideoCapabilitiesKHR(3)

Name

vkGetPhysicalDeviceVideoCapabilitiesKHR - Query video coding capabilities

C Specification

To query video coding capabilities for a specific video profile, call:

// Provided by VK_KHR_video_queue
VkResult vkGetPhysicalDeviceVideoCapabilitiesKHR(
    VkPhysicalDevice                            physicalDevice,
    const VkVideoProfileInfoKHR*                pVideoProfile,
    VkVideoCapabilitiesKHR*                     pCapabilities);

Parameters

  • physicalDevice is the physical device from which to query the video decode or encode capabilities.

  • pVideoProfile is a pointer to a VkVideoProfileInfoKHR structure.

  • pCapabilities is a pointer to a VkVideoCapabilitiesKHR structure in which the capabilities are returned.

Description

If the video profile described by pVideoProfile is supported by the implementation, then this command returns VK_SUCCESS and pCapabilities is filled with the capabilities supported with the specified video profile. Otherwise, one of the video-profile-specific error codes are returned.

Valid Usage
  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-07183
    If pVideoProfile->videoCodecOperation specifies a decode operation, then the pNext chain of pCapabilities must include a VkVideoDecodeCapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-07184
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_DECODE_H264_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoDecodeH264CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-07185
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_DECODE_H265_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoDecodeH265CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-10792
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_DECODE_VP9_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoDecodeVP9CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-09257
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_DECODE_AV1_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoDecodeAV1CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-07186
    If pVideoProfile->videoCodecOperation specifies an encode operation, then the pNext chain of pCapabilities must include a VkVideoEncodeCapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-07187
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_ENCODE_H264_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoEncodeH264CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-07188
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_ENCODE_H265_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoEncodeH265CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-10263
    If pVideoProfile->videoCodecOperation is VK_VIDEO_CODEC_OPERATION_ENCODE_AV1_BIT_KHR, then the pNext chain of pCapabilities must include a VkVideoEncodeAV1CapabilitiesKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pNext-10921
    If the pNext chain of pVideoProfile includes a VkVideoEncodeProfileRgbConversionInfoVALVE structure, then the videoEncodeRgbConversion feature must be supported

Valid Usage (Implicit)
  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-physicalDevice-parameter
    physicalDevice must be a valid VkPhysicalDevice handle

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pVideoProfile-parameter
    pVideoProfile must be a valid pointer to a valid VkVideoProfileInfoKHR structure

  • VUID-vkGetPhysicalDeviceVideoCapabilitiesKHR-pCapabilities-parameter
    pCapabilities must be a valid pointer to a VkVideoCapabilitiesKHR structure

Return Codes
Success
  • VK_SUCCESS

Failure
  • VK_ERROR_OUT_OF_DEVICE_MEMORY

  • VK_ERROR_OUT_OF_HOST_MEMORY

  • VK_ERROR_UNKNOWN

  • VK_ERROR_VALIDATION_FAILED

  • VK_ERROR_VIDEO_PICTURE_LAYOUT_NOT_SUPPORTED_KHR

  • VK_ERROR_VIDEO_PROFILE_CODEC_NOT_SUPPORTED_KHR

  • VK_ERROR_VIDEO_PROFILE_FORMAT_NOT_SUPPORTED_KHR

  • VK_ERROR_VIDEO_PROFILE_OPERATION_NOT_SUPPORTED_KHR

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.