hi_isp_ae_stats_cfg
Description
Defines the AE statistics configuration.
Definition
typedef struct {
hi_isp_ae_switch ae_switch;
hi_isp_ae_hist_config hist_config;
hi_isp_ae_four_plane_mode four_plane_mode;
hi_isp_ae_stat_mode hist_mode;
hi_isp_ae_stat_mode aver_mode;
hi_isp_ae_stat_mode max_gain_mode;
hi_isp_ae_crop crop;
hi_u8 weight[HI_ISP_AE_ZONE_ROW][HI_ISP_AE_ZONE_COLUMN];
} hi_isp_ae_stats_cfg;
Members
Member |
Description |
|---|---|
ae_switch |
Position of the AE statistical module in the ISP pipeline after the WDR fusion. The default value is 1. |
hist_config |
Mode configuration for the sampling points during global histogram statistics |
four_plane_mode |
four_plane_mode enable. The default value is 0. When it is enabled, the 1024-segment histogram is equal to the 256-segment histograms of four channels (R, Gr, Gb, B). |
hist_mode |
Enabling of the root extraction mode for the global 1024-segment histogram. Only the statistics of the BE histogram are affected. |
aver_mode |
Enabling the root extraction mode for the mean values, affecting the statistics of the BE mean values only |
max_gain_mode |
Enabling of the root extraction mode for the MG module. Only the statistics of the MG module are affected. To compare with the AE block statistics, you are advised to set this member to the same mode as aver_mode. |
crop |
Cropping configuration of the AE input image |
weight |
AE weight table of 15 x 17 zones. The value range is [0, 15]. #define HI_ISP_AE_ZONE_COLUMN 17 #define HI_ISP_AE_ZONE_ROW 15 |
Restrictions
- In linear mode, data streams are transmitted through channel 1. By default, the global 1024-segment histogram is used for AE control. In this case, the global 1024-segment histograms of channels 2, 3, and 4 are all 0s before WDR fusion.
- The average values of four components in global statistics are affected by the 15 x 17 weight table.
- The global 1024-segment histograms of channels 1, 2, 3, and 4 are affected by the 15 x 17 weight table. In WDR mode, the information about these histograms can be used for AE control. For example, channels 1/2 can be used in 2-to-1 mode, channels 1/2/3 can be used in 3-to-1 mode, and channels 1/2/3/4 can be used in 4-to-1 mode.
- When configuring ae_switch, hist_config, four_plane_mode, you need to disable the large-area single-color judgment function of the Ascend AE. For details about how to disable the function, see hist_stat_adjust of hi_isp_exposure_attr.
- The static AE statistics are divided into 15 x 17 zones. You can change the weight of each zone by setting the weight table. For example, increasing the weight of the central zone changes the luminance of the central zone, which results in the statistics change of the global histogram. This attribute can be used to adjust the exposure weights of ROIs and implement backlight compensation for specified regions. If you can determine the ROI positions of a specific product, you can increase the weight of these regions. For example, the ROI is typically in the middle and lower part of the image for the motion DV and event data recorder (EDR). Therefore, the weight of the middle and lower area can be properly increased to ensure that the exposure of the ROI is appropriate.