VkVideoEncodeH264RateControlLayerInfoKHR(3)

# VkVideoEncodeH264RateControlLayerInfoKHR(3) Manual Page

## Name

VkVideoEncodeH264RateControlLayerInfoKHR - Structure describing H.264 per-layer rate control parameters

## C Specification

The `VkVideoEncodeH264RateControlLayerInfoKHR` structure is defined as:

    // Provided by VK_KHR_video_encode_h264
    typedef struct VkVideoEncodeH264RateControlLayerInfoKHR {
        VkStructureType                  sType;
        const void*                      pNext;
        VkBool32                         useMinQp;
        VkVideoEncodeH264QpKHR           minQp;
        VkBool32                         useMaxQp;
        VkVideoEncodeH264QpKHR           maxQp;
        VkBool32                         useMaxFrameSize;
        VkVideoEncodeH264FrameSizeKHR    maxFrameSize;
    } VkVideoEncodeH264RateControlLayerInfoKHR;

## Members

- `sType` is a VkStructureType value identifying this structure.

- `pNext` is `NULL` or a pointer to a structure extending this structure.

- `useMinQp` indicates whether the QP values determined by rate control will be clamped to the lower bounds on the QP values specified in `minQp`.

- `minQp` specifies the lower bounds on the QP values, for each picture type, that the implementation’s rate control algorithm will use when `useMinQp` is VK_TRUE.

- `useMaxQp` indicates whether the QP values determined by rate control will be clamped to the upper bounds on the QP values specified in `maxQp`.

- `maxQp` specifies the upper bounds on the QP values, for each picture type, that the implementation’s rate control algorithm will use when `useMaxQp` is VK_TRUE.

- `useMaxFrameSize` indicates whether the implementation’s rate control algorithm should use the values specified in `maxFrameSize` as the upper bounds on the encoded frame size for each picture type.

- `maxFrameSize` specifies the upper bounds on the encoded frame size, for each picture type, when `useMaxFrameSize` is VK_TRUE.

## Description

When used, the values in `minQp` and `maxQp` guarantee that the effective QP values used by the implementation will respect those lower and upper bounds, respectively. However, limiting the range of QP values that the implementation is able to use will also limit the capabilities of the implementation’s rate control algorithm to comply to other constraints. In particular, the implementation may not be able to comply to the following:

- The average and/or peak bitrate values to be used for the encoded bitstream specified in the `averageBitrate` and `maxBitrate` members of the VkVideoEncodeRateControlLayerInfoKHR structure.

- The upper bounds on the encoded frame size, for each picture type, specified in the `maxFrameSize` member of `VkVideoEncodeH264RateControlLayerInfoKHR`.

Note | In general, applications need to configure rate control parameters appropriately in order to be able to get the desired rate control behavior, as described in the Video Encode Rate Control section.

When an instance of this structure is included in the `pNext` chain of a VkVideoEncodeRateControlLayerInfoKHR structure specified in one of the elements of the `pLayers` array member of the VkVideoEncodeRateControlInfoKHR structure passed to the vkCmdControlVideoCodingKHR command, VkVideoCodingControlInfoKHR::`flags` includes VK_VIDEO_CODING_CONTROL_ENCODE_RATE_CONTROL_BIT_KHR, and the bound video session was created with the video codec operation VK_VIDEO_CODEC_OPERATION_ENCODE_H264_BIT_KHR, it specifies the H.264-specific rate control parameters of the rate control layer corresponding to that element of `pLayers`.

Valid Usage

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-useMinQp-08286
  If `useMinQp` is VK_TRUE, then the `qpI`, `qpP`, and `qpB` members of `minQp` must all be between VkVideoEncodeH264CapabilitiesKHR::`minQp` and VkVideoEncodeH264CapabilitiesKHR::`maxQp`, as returned by vkGetPhysicalDeviceVideoCapabilitiesKHR for the used video profile

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-useMaxQp-08287
  If `useMaxQp` is VK_TRUE, then the `qpI`, `qpP`, and `qpB` members of `maxQp` must all be between VkVideoEncodeH264CapabilitiesKHR::`minQp` and VkVideoEncodeH264CapabilitiesKHR::`maxQp`, as returned by vkGetPhysicalDeviceVideoCapabilitiesKHR for the used video profile

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-useMinQp-08288
  If `useMinQp` is VK_TRUE and VkVideoEncodeH264CapabilitiesKHR::`flags`, as returned by vkGetPhysicalDeviceVideoCapabilitiesKHR for the used video profile, does not include VK_VIDEO_ENCODE_H264_CAPABILITY_PER_PICTURE_TYPE_MIN_MAX_QP_BIT_KHR, then the `qpI`, `qpP`, and `qpB` members of `minQp` must all specify the same value

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-useMaxQp-08289
  If `useMaxQp` is VK_TRUE and VkVideoEncodeH264CapabilitiesKHR::`flags`, as returned by vkGetPhysicalDeviceVideoCapabilitiesKHR for the used video profile, does not include VK_VIDEO_ENCODE_H264_CAPABILITY_PER_PICTURE_TYPE_MIN_MAX_QP_BIT_KHR, then the `qpI`, `qpP`, and `qpB` members of `maxQp` must all specify the same value

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-useMinQp-08374
  If `useMinQp` and `useMaxQp` are both VK_TRUE, then the `qpI`, `qpP`, and `qpB` members of `minQp` must all be less than or equal to the respective members of `maxQp`

Valid Usage (Implicit)

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-sType-sType
  `sType` must be VK_STRUCTURE_TYPE_VIDEO_ENCODE_H264_RATE_CONTROL_LAYER_INFO_KHR

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-minQp-parameter
  `minQp` must be a valid VkVideoEncodeH264QpKHR structure

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-maxQp-parameter
  `maxQp` must be a valid VkVideoEncodeH264QpKHR structure

- VUID-VkVideoEncodeH264RateControlLayerInfoKHR-maxFrameSize-parameter
  `maxFrameSize` must be a valid VkVideoEncodeH264FrameSizeKHR structure

Structure Chaining

Extends the structure

  - VkVideoEncodeRateControlLayerInfoKHR

## See Also

VK_KHR_video_encode_h264, VkBool32, VkStructureType, VkVideoEncodeH264FrameSizeKHR, VkVideoEncodeH264QpKHR

## 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-2026 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0