Structures

VkVideoEncodeRateControlLayerInfoKHR

Structure to set encode per-layer rate control parameters

The VkVideoEncodeRateControlLayerInfoKHR structure is defined as:

typedef struct VkVideoEncodeRateControlLayerInfoKHR {
    VkStructureType sType;
    const void* pNext;
    uint64_t averageBitrate;
    uint64_t maxBitrate;
    uint32_t frameRateNumerator;
    uint32_t frameRateDenominator;
} VkVideoEncodeRateControlLayerInfoKHR;
  • sType is a VkStructureType value identifying this structure.
  • pNext is a pointer to a structure extending this structure.
  • averageBitrate is the average bitrate to be targeted by the implementation’s rate control algorithm.
  • maxBitrate is the peak bitrate to be targeted by the implementation’s rate control algorithm.
  • frameRateNumerator is the numerator of the frame rate assumed by the implementation’s rate control algorithm.
  • frameRateDenominator is the denominator of the frame rate assumed by the implementation’s rate control algorithm.

The ability of the implementation’s rate control algorithm to be able to match the requested average and/or peak bitrates may be limited by the set of other codec-independent and codec-specific rate control parameters specified by the application, the input content, as well as the application conforming to the rate control guidance provided to the implementation, as described earlier.

Additional structures providing codec-specific rate control parameters can be included in the pNext chain of VkVideoEncodeRateControlLayerInfoKHR depending on the video profile the bound video session was created with. For further details see:

Valid Usage

VUID-VkVideoEncodeRateControlLayerInfoKHR-frameRateNumerator-08350

frameRateNumerator must be greater than zero

VUID-VkVideoEncodeRateControlLayerInfoKHR-frameRateDenominator-08351

frameRateDenominator must be greater than zero

Valid Usage (Implicit)

VUID-VkVideoEncodeRateControlLayerInfoKHR-sType-sType

sType must be VK_STRUCTURE_TYPE_VIDEO_ENCODE_RATE_CONTROL_LAYER_INFO_KHR

VUID-VkVideoEncodeRateControlLayerInfoKHR-pNext-pNext

Each pNext member of any structure (including this one) in the pNext chain must be either NULL or a pointer to a valid instance of VkVideoEncodeH264RateControlLayerInfoKHR or VkVideoEncodeH265RateControlLayerInfoKHR

VUID-VkVideoEncodeRateControlLayerInfoKHR-sType-unique

The sType value of each struct in the pNext chain must be unique