hi_isp_exposure_attr

Description

Defines the ISP exposure attribute.

Definition

typedef struct {
    hi_bool             bypass;
    hi_op_mode          op_type;
    hi_u8               ae_run_interval;
    hi_bool             hist_stat_adjust;
    hi_bool             ae_route_ex_valid;
    hi_isp_me_attr      manual_attr;
    hi_isp_ae_attr      auto_attr;
    hi_isp_prior_frame  prior_frame;
    hi_bool             ae_gain_sep_cfg;
    hi_bool             advance_ae;
} hi_isp_exposure_attr;

Members

Member

Description

bypass

AE bypass enable. The default value is HI_FALSE.

op_type

Automatic or manual exposure enable. The default value is HI_OP_MODE_AUTO.

ae_run_interval

Running interval of the AE algorithm. The value range is [1, 255].

  • The value 1 indicates that the AE algorithm runs for each frame.
  • The value 2 indicates that the AE algorithm runs once every two frames. The rest follows the same rule. It is recommended that the configured value be less than or equal to 2. Otherwise, the AE adjustment speed is affected.

    In WDR mode, the recommended value is 1 for smoother AE convergence.

    The default value is 1.

hist_stat_adjust

Whether to adjust the statistical mode of the 1024-segment histogram based on the scenario. The default value is HI_TRUE.

ae_route_ex_valid

Whether the extended AE allocation route is valid. When the value is set to HI_TRUE, the extended AE allocation route is used; otherwise, the common AE allocation route is used. The default value is HI_FALSE.

manual_attr

ME attribute

auto_attr

AE attribute

prior_frame

Priority frame for the exposure route to take effect in WDR mode. In linear mode, this parameter must be set to LONG_FRAME.

ae_gain_sep_cfg

Whether to allocate the gains for long and short frames separately

advance_ae

Advanced AE enable

Restrictions

  • When AE bypass is set to HI_TRUE, the AE module is bypassed, and configuring the AE module has no effect on the image luminance. hi_isp_ae_result is the value of the previous frame of AE bypass.
  • The Ascend AE algorithm adjusts the luminance based on the global 1024-segment histogram. In normal scenarios, the 1024-segment histogram collects only the Gb or Gr component for statistics. If hist_stat_adjust is set to HI_TRUE in the scenario where there is a large region with a single color (for example, red or blue), the AE algorithm adjusts the statistical mode of the 1024-segment histogram based on the global average value (the R component or B component is considered). In this way, the image luminance will not be too high in the scenario with a large red or blue region. If hist_stat_adjust is set to HI_FALSE, the AE algorithm does not adjust the statistical mode of the 1024-segment histogram. You are advised to set hist_stat_adjust to HI_FALSE in the infrared scenario.
  • During the switchover between the WDR mode and linear mode, ae_run_interval is reset to 1. You can change the value as required after switching is complete.
  • ae_gain_sep_cfg takes effect only in 2-to-1 WDR mode.
  • The manual mode does not support separate gain configuration for long frames and short frames.
  • During the change of the exposure ratio, switching ae_gain_sep_cfg will affect the exposure time limits of the long and short frames, which may cause the sudden change of the image luminance. Therefore, you are advised to switch ae_gain_sep_cfg when the exposure ratio is converged.
  • Currently, advance_ae takes effect in normal FSWDR mode (long frames not supported). Enabling advance_ae makes the exposure of dark and bright regions more proper and accurate. When the bright-to-dark ratio changes, the exposure of dark and bright regions becomes more stable. However, enabling advance_ae makes little difference in other scenarios.