hi_isp_drc_attr
Description
Defines the ISP DRC attribute.
Definition
typedef struct {
hi_bool enable;
hi_isp_drc_curve_select curve_select;
hi_u8 purple_reduction_strength;
hi_u8 local_mixing_bright_max;
hi_u8 local_mixing_bright_min;
hi_u8 local_mixing_bright_thr;
hi_s8 local_mixing_bright_slo;
hi_u8 local_mixing_dark_max;
hi_u8 local_mixing_dark_min;
hi_u8 local_mixing_dark_thr;
hi_s8 local_mixing_dark_slo;
hi_u8 bright_gain_lmt;
hi_u8 bright_gain_lmt_step;
hi_u8 dark_gain_lmt_y;
hi_u8 dark_gain_lmt_c;
hi_u16 color_correction_lut[HI_ISP_DRC_CC_NODE_NUM];
hi_u16 tone_mapping_value[HI_ISP_DRC_TM_NODE_NUM];
hi_u8 contrast_control;
hi_s8 detail_adjust_factor;
hi_u8 spatial_flt_coef;
hi_u8 range_flt_coef;
hi_u8 range_ada_max;
hi_u8 grad_rev_max;
hi_u8 grad_rev_thr;
hi_op_mode op_type;
hi_isp_drc_manual_attr manual_attr;
hi_isp_drc_auto_attr auto_attr;
hi_isp_drc_asymmetry_curve_attr asymmetry_curve;
} hi_isp_drc_attr;
Members
Member |
Description |
|---|---|
enable |
Dynamic range compression enable for the DRC. The options are as follows:
|
curve_select |
DRC tone mapping curve select. The options are as follows:
|
purple_reduction_strength |
Strength of purple fringing correction. A larger value indicates greater correction strength. Value range: [0x0, 0x80] |
local_mixing_bright_max |
Parameter used for controlling the maximum gain for positive details (linear detail enhancement) Value range: [0x0, 0x80] |
local_mixing_bright_min |
Parameter used for controlling the minimum gain for positive details (linear detail enhancement) Value range: [0x0, 0x40] |
local_mixing_bright_thr |
Parameter used for controlling the threshold of the positive detail gain that is adaptive to the luminance (linear detail enhancement) When the pixel luminance exceeds the threshold, the gain shifts from the maximum value to the minimum value (depending on the plus-minus sign of the slope parameter). Value range: [0x0, 0xFF] |
local_mixing_bright_slo |
Parameter used for controlling the slope parameter of the positive detail gain that is adaptive to the luminance (linear detail enhancement). A larger absolute value indicates a faster shift from the minimum value to the maximum value and vice versa. Value range: [-0x7, 0x7] |
local_mixing_dark_max |
Parameter used for controlling the maximum gain for negative details (linear detail enhancement) Value range: [0x0, 0x80] |
local_mixing_dark_min |
Parameter used for controlling the minimum gain for negative details (linear detail enhancement) Value range: [0x0, 0x40] |
local_mixing_dark_thr |
Parameter used for controlling the threshold of the negative detail gain that is adaptive to the luminance (linear detail enhancement). When the pixel luminance exceeds the threshold, the gain shifts from the minimum value to the maximum value (depending on the plus-minus sign of the slope parameter). Value range: [0x0, 0xFF] |
local_mixing_dark_slo |
Parameter used for controlling the slope parameter of the negative detail gain that is adaptive to the luminance (linear detail enhancement). A larger absolute value indicates a faster shift from the minimum value to the maximum value and vice versa. Value range: [-0x7, 0x7] |
bright_gain_lmt |
Target value of the luminance gain limit of the bright region. A larger value indicates a higher limit. Value range: [0x0, 0xF] |
bright_gain_lmt_step |
Adaptive step of the luminance gain limit of the bright region. A smaller value indicates a higher limit. Value range: [0x0, 0xF] |
dark_gain_lmt_y |
Luminance gain limit of the dark region. A larger value indicates a higher limit. Value range: [0x0, 0x85] |
dark_gain_lmt_c |
Chrominance gain limit of the dark region A larger value indicates a higher limit. Value range: [0x0, 0x85] |
color_correction_lut[HI_ISP_DRC_CC_NODE_NUM] |
Color correction coefficient LUT. A smaller value indicates lower saturation. Value range: [0x0, 0x400] #define HI_ISP_DRC_CC_NODE_NUM 33 |
tone_mapping_value[HI_ISP_DRC_TM_NODE_NUM] |
User-defined tone mapping curve LUT. Value range: [0x0, 0xFFFF] #define HI_ISP_DRC_TM_NODE_NUM 200 |
contrast_control |
Local contrast control. The parameter effect is related to the image luminance distribution. The recommended value range is 6 to 10. Value range: [0x0, 0xF] |
detail_adjust_factor |
Detail adjustment coefficient for the filter. A larger value indicates stronger overall detail. Value range: [-0xF, 0xF] |
spatial_flt_coef |
Spatial filtering coefficient for the filter. A larger value indicates less obvious motion halo and a smaller number of details. A smaller value indicates better details and more obvious motion halo. Value range: [0x0, 0x5] |
range_flt_coef |
Range filtering coefficient for the filter. A larger value indicates more obvious halo. And a smaller value indicates less obvious halo but more possible borders at strong edges. Value range: [0x0, 0xA] |
range_ada_max |
Adaptive range of the filtering coefficient. The filtering coefficient that takes effect is within the range of [range_flt_coef, MIN(range_flt_coef + range_ada_max, 0xA)]. Increasing the value of this parameter helps to weaken the boundaries, but may cause the loss of the details of the backlight object. Value range: [0x0, 0x8] |
grad_rev_max |
Strength of border line correction. A larger value indicates that the border line is weakened more obviously, but may cause details loss. Value range: [0x0, 0x40] |
grad_rev_thr |
Border line detection threshold. A larger value indicates that the border line is weakened more obviously, but may cause details loss. Value range: [0x0, 0x80] |
op_type |
DRC operating mode. The options are as follows:
|
manual_attr |
Manual DRC parameter |
auto_attr |
Automatic DRC parameter |
asymmetry_curve |
DRC asymmetry curve attribute |
Restrictions
- It is recommended that the value of color_correction_lut not be set to a too small value. Otherwise, high-frequency details are lost when the saturation is reduced. You can adjust the overall saturation by using the CA module.
- For dark_gain_lmt_y and dark_gain_lmt_c, the adjustment between adjacent values may bring sudden effect change.