37. CLUT¶
37.1. Function Overview¶
Linear conversion is done on RGB domain through a 17x17x17 3D LUT. The RGB pixel values can be interpolated into the table to obtain new RGB pixel values, which can be used to debug the color and brightness.
37.2. API Reference¶
CVI_ISP_SetClutAttr : Set CLUT attribute parameter
CVI_ISP_GetClutAttr : Get CLUT attribute parameter
CVI_ISP_SetClutSaturationAttr : Set CLUT SbyS attribute parameter
CVI_ISP_GetClutSaturationAttr : Get CLUT SbyS attribute parameter
37.2.1. CVI_ISP_SetClutAttr¶
【Description】
Set CLUT attribute parameter
【Syntax】
CVI_S32 CVI_ISP_SetClutAttr(VI_PIPE ViPipe, const ISP_CLUT_ATTR_S *pstClutAttr);
【Parameter】
Parameter |
Description |
Input/Output |
---|---|---|
ViPipe |
VI_PIPE number |
Input |
pstCLUTAttr |
CLUT attribute parameter |
Input |
【Return Value】
Return value |
Description |
---|---|
0 |
Success |
Non 0 |
Failure. An error code is returned. For details, see chapter Error Codes. |
【Requirement】
Header files:cvi_isp.h, cvi_comm_isp.h
Library files: libisp.so
【Note】
None.
【example】
None.
【Related Topic】
37.2.2. CVI_ISP_GetClutAttr¶
【Description】
Get CLUT attribute parameter
【Syntax】
【Parameter】
Parameter |
Description |
Input/Output |
---|---|---|
ViPipe |
VI_PIPE number |
Input |
pstCLUTAttr |
CLUT attribute parameter |
Output |
【Return Value】
Return value |
Description |
---|---|
0 |
Success |
Non 0 |
Failure. An error code is returned. For details, see chapter Error Codes. |
【Requirement】
Header files:cvi_isp.h, cvi_comm_isp.h
Library files: libisp.so
【Note】
None.
【example】
None.
【Related Topic】
37.2.3. CVI_ISP_SetClutSaturationAttr¶
【Description】
Set CLUT SbyS attribute parameter
【Syntax】
CVI_S32 CVI_ISP_SetClutSaturationAttr(VI_PIPE ViPipe, ISP_CLUT_SATURATION_ATTR_S *pstClutSaturationAttr);
【Parameter】
Parameter |
Description |
Input/Output |
---|---|---|
ViPipe |
VI_PIPE number |
Input |
pstClutSaturationAttr |
CLUT SbyS attribute parameter |
Input |
【Return Value】
Return value |
Description |
---|---|
0 |
Success |
Non 0 |
Failure. An error code is returned. For details, see chapter Error Codes. |
【Requirement】
Header files:cvi_isp.h, cvi_comm_isp.h
Library files: libisp.so
【Note】
None.
【example】
None.
【Related Topic】
37.2.4. CVI_ISP_GetClutSaturationAttr¶
【Description】
Get CLUT SbyS attribute parameter
【Syntax】
CVI_S32 CVI_ISP_GetClutSaturationAttr(VI_PIPE ViPipe, ISP_CLUT_SATURATION_ATTR_S *pstClutSaturationAttr);
【Parameter】
Parameter |
Description |
Input/Output |
---|---|---|
ViPipe |
VI_PIPE number |
Input |
pstClutSaturationAttr |
CLUT SbyS attribute parameter |
Output |
【Return Value】
Return value |
Description |
---|---|
0 |
Success |
Non 0 |
Failure. An error code is returned. For details, see chapter Error Codes. |
【Requirement】
Header files:cvi_isp.h, cvi_comm_isp.h
Library files: libisp.so
【Note】
None.
【example】
None.
【Related Topic】
37.3. Data Types¶
ISP_CLUT_ATTR_S : CLUT attribute parameter
ISP_CLUT_SATURATION_MANUAL_ATTR_S : CLUT SbyS attribute manual parameter
ISP_CLUT_SATURATION_AUTO_ATTR_S : CLUT SbyS attribute automatic parameter
ISP_CLUT_SATURATION_ATTR_S : CLUT SbyS attribute parameter
37.3.1. ISP_CLUT_ATTR_S¶
【Description】
CLUT attribute parameter
【Syntax】
typedef struct _ISP_CLUT_ATTR_S {
CVI_BOOL Enable;
CVI_U8 UpdateInterval;
CVI_U16 ClutR[ISP_CLUT_LUT_LENGTH];
CVI_U16 ClutG[ISP_CLUT_LUT_LENGTH];
CVI_U16 ClutB[ISP_CLUT_LUT_LENGTH];
} ISP_CLUT_ATTR_S;
【Member】
Member |
Description |
---|---|
Enable |
The CLUT module is enabled. 0: off. 1: Enabled. Value range: [0, 1] Data Type: CVI_BOOL |
UpdateInterval |
Affects the parameter update interval, the larger the value, the slower the screen changes and the better the performance. Value range: [0x0, 0xff] Data Type: CVI_U8 |
ClutR |
LUT for the R channel. Value range: [0x0, 0x3ff] Data Type: CVI_U16 |
ClutG |
LUT for the G channel. Value range: [0x0, 0x3ff] Data Type: CVI_U16 |
ClutB |
LUT for the B channel. Value range: [0x0, 0x3ff] Data Type: CVI_U16 |
【Note】
None.
【Related Data Type and Interface】
37.3.2. ISP_CLUT_SATURATION_MANUAL_ATTR_S¶
【Description】
CLUT SbyS attribute manual parameter
【Syntax】
typedef struct _ISP_CLUT_SATURATION_MANUAL_ATTR_S {
CVI_U16 SatIn[4];
CVI_U16 SatOut[4];
} ISP_CLUT_SATURATION_MANUAL_ATTR_S;
【Member】
Member |
Description |
---|---|
SatIn [4] |
SatIn [4] SbyS input Value range: [0, 0x2000] Data Type: CVI_U16 |
SatOut [4] |
SatOut [4] SbyS output Value range: [0, 0x2000] Data Type: CVI_U16 |
【Note】
None.
【Related Data Type and Interface】
37.3.3. ISP_CLUT_SATURATION_AUTO_ATTR_S¶
【Description】
CLUT SbyS attribute automatic parameter
【Syntax】
typedef struct _ISP_CLUT_SATURATION_AUTO_ATTR_S {
CVI_U16 SatIn[4][ISP_AUTO_ISO_STRENGTH_NUM];
CVI_U16 SatOut[4][ISP_AUTO_ISO_STRENGTH_NUM];
} ISP_CLUT_SATURATION_AUTO_ATTR_S;
【Member】
Member |
Description |
---|---|
SatIn [4] |
SatIn [4] SbyS input Value range: [0, 0x2000] Data Type: CVI_U16 |
SatOut [4] |
SatOut [4] SbyS output Value range: [0, 0x2000] Data Type: CVI_U16 |
【Note】
None.
【Related Data Type and Interface】
37.3.4. ISP_CLUT_SATURATION_ATTR_S¶
【Description】
CLUT SbyS attribute parameter
【Syntax】
typedef struct _ISP_CLUT_SATURATION_ATTR_S {
CVI_BOOL Enable;
ISP_OP_TYPE_E enOpType;
ISP_CLUT_SATURATION_MANUAL_ATTR_S stManual;
ISP_CLUT_SATURATION_AUTO_ATTR_S stAuto;
} ISP_CLUT_SATURATION_ATTR_S;
【Member】
Member |
Description |
---|---|
Enable |
SbyS module enable. 0: off. 1: Enabled. Value range: [0, 1] Data Type: CVI_BOOL |
enOpType |
Select manual or automatic mode |
stManual |
Manual mode parameter attribute |
stAuto |
Auto mode parameter attribute |
【Note】
None.
【Related Data Type and Interface】