hi_dis_config

Description

Defines the DIS configuration information.

Prototype

typedef struct {
    hi_dis_mode         mode;
    hi_dis_motion_level motion_level;
    hi_dis_pdt_type     pdt_type;
    hi_u32           buf_num;
    hi_u32           crop_ratio;
    hi_u32           frame_rate;
    hi_bool camera_steady;
    hi_bool scale;
} hi_dis_config;

Members

Member

Description

mode

Multi-degree DIS algorithm. There are three algorithms in total.

motion_level

Motion level of the camera

pdt_type

Product form with the DIS function. The IPC, DV, and drone camera are supported currently.

buf_num

Number of memory blocks used by the DIS to store images. The number of buffers can be increased if frame loss occurs for the DIS output frames.

Value range: [5, 10].

crop_ratio

Cropping ratio of the DIS output image.

Value range: [50, 98]

frame_rate

Set this parameter to the actual frame rate of the VI output. Value range: (0, 60]

  • When the DIS mode is HI_DIS_MODE_4_DOF_GME or HI_DIS_MODE_6_DOF_GME, a low frame rate increases the interval between two frames and increases the jitter amplitude between two frames. In addition, the rolling shutter effect is more serious. It is expected that the DIS effect may deteriorate, especially in scenarios with large jitter amplitude.
  • When the DIS mode is HI_DIS_MODE_GYRO, the maximum sampling rate of the gyroscope supported by the algorithm decreases except that the DIS effect is the same as that of the GME. The current 3.5 kHz specification is designed based on the minimum 25 fps. If the value decreases, the maximum sampling rate of the supported gyroscope also decreases.

camera_steady

Whether the camera is steady.

The options are as follows:

  • HI_FALSE: not steady.
  • HI_TRUE: steady.

scale

Whether to scale up the output image after cropping Currently, the DIS allows you to determine whether to zoom in the cropped output picture. If you do not want to use the DIS zoom-in function, you can use the backend VPSS to zoom in.

The options are as follows:

  • HI_FALSE: no zoom-in.
  • HI_TRUE: zoom in.

When scale is set to HI_FALSE, the width and height of the output picture are the width and height of the input picture multiplied by the cropping ratio configured by crop_ratio, and the value is 2-pixel aligned.