xref: /OK3568_Linux_fs/external/camera_engine_rkaiq/rkaiq/include/algos/alsc/rk_aiq_types_alsc_hw.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /*
2  *rk_aiq_types_alsc_hw.h
3  *
4  *  Copyright (c) 2019 Rockchip Corporation
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  *      http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  *
18  */
19 
20 #ifndef _RK_AIQ_TYPE_ALSC_HW_H_
21 #define _RK_AIQ_TYPE_ALSC_HW_H_
22 
23 #include "rk_aiq_comm.h"
24 #define LSC_DATA_TBL_V_SIZE         17
25 #define LSC_DATA_TBL_H_SIZE         17
26 //MEMO: rkisp2-config.h/rkisp3-config.h -> ISP2X_LSC_DATA_TBL_SIZE is 290
27 #define LSC_DATA_TBL_SIZE           289
28 
29 #define LSC_GRAD_TBL_SIZE           16
30 #define LSC_SIZE_TBL_SIZE           16
31 
32 RKAIQ_BEGIN_DECLARE
33 
34 /**
35  * @brief LSC config table to be set to hardware.
36  * Remember, 4 channel data array must be in the head of struct,
37  * and with the order of (r, gr, gb, b)!
38 */
39 typedef struct rk_aiq_lsc_cfg_s {
40     unsigned short r_data_tbl[LSC_DATA_TBL_SIZE];
41     unsigned short gr_data_tbl[LSC_DATA_TBL_SIZE];
42     unsigned short gb_data_tbl[LSC_DATA_TBL_SIZE];
43     unsigned short b_data_tbl[LSC_DATA_TBL_SIZE];
44 
45     unsigned short x_grad_tbl[LSC_GRAD_TBL_SIZE];
46     unsigned short y_grad_tbl[LSC_GRAD_TBL_SIZE];
47     unsigned short x_size_tbl[LSC_SIZE_TBL_SIZE];
48     unsigned short y_size_tbl[LSC_SIZE_TBL_SIZE];
49     bool lsc_en;
50 } rk_aiq_lsc_cfg_t;
51 
52 RKAIQ_END_DECLARE
53 
54 #endif
55 
56