hi_venc_roi_attr

Function

Defines the ROI information.

Definition

typedef struct {
    hi_u32   idx;
    hi_bool  enable;
    hi_bool  is_abs_qp;
    hi_s32   qp;
    hi_rect  rect;
} hi_venc_roi_attr;

For details about basic data types hi_u32, hi_bool, and hi_s32, see Basic Data Types.

Members

Member

Description

idx

ROI index, ranging from 0 to 7.

A maximum of eight ROIs (indexed from 0 to 7) can be configured for each channel. The eight ROIs can be overlaid with each other, in an ascending overlaying priority according to the index numbers 0–7.

enable

Whether to enable the ROI.

Ensure that Cb and Cr components are the same.

is_abs_qp

QP mode of the current ROI.

  • HI_FALSE: relative QP
  • HI_TRUE: absolute QP

qp

QP value. When the QP mode is set to HI_FALSE, this parameter indicates the QP offset, in the range of [–51, +51]. When the QP mode is set to HI_TRUE, this parameter indicates the macroblock QP value, in the range of [0, 51].

rect

Position coordinates and size of the current ROI. For details, see hi_rect.

The start point coordinates of the ROI must be within the image and be multiples of 16. The height and width of the ROI must also be multiples of 16 and greater than 0. That is, the X-coordinate, Y-coordinate, width, and height must be multiples of 16.