blob: a54c44c36da5dc7a5df002e0b7ba235ceaf86d5f
1 | #ifndef __VE_H |
2 | #define __VE_H |
3 | |
4 | // *************************************************************************** |
5 | // *** enum definitions ********************************************* |
6 | // *************************************************************************** |
7 | |
8 | typedef enum ve_demo_pos_e { |
9 | VE_DEMO_POS_TOP = 0, |
10 | VE_DEMO_POS_BOTTOM, |
11 | VE_DEMO_POS_LEFT, |
12 | VE_DEMO_POS_RIGHT, |
13 | } ve_demo_pos_t; |
14 | |
15 | typedef enum ve_dnlp_rt_e { |
16 | VE_DNLP_RT_0S = 0, |
17 | VE_DNLP_RT_1S = 6, |
18 | VE_DNLP_RT_2S, |
19 | VE_DNLP_RT_4S, |
20 | VE_DNLP_RT_8S, |
21 | VE_DNLP_RT_16S, |
22 | VE_DNLP_RT_32S, |
23 | VE_DNLP_RT_64S, |
24 | VE_DNLP_RT_FREEZE, |
25 | } ve_dnlp_rt_t; |
26 | |
27 | // *************************************************************************** |
28 | // *** struct definitions ********************************************* |
29 | // *************************************************************************** |
30 | |
31 | typedef enum ve_dnlp_rl_e { |
32 | VE_DNLP_RL_01 = 1, // max_contrast = 1.0625x |
33 | VE_DNLP_RL_02, // max_contrast = 1.1250x |
34 | VE_DNLP_RL_03, // max_contrast = 1.1875x |
35 | VE_DNLP_RL_04, // max_contrast = 1.2500x |
36 | VE_DNLP_RL_05, // max_contrast = 1.3125x |
37 | VE_DNLP_RL_06, // max_contrast = 1.3750x |
38 | VE_DNLP_RL_07, // max_contrast = 1.4375x |
39 | VE_DNLP_RL_08, // max_contrast = 1.5000x |
40 | VE_DNLP_RL_09, // max_contrast = 1.5625x |
41 | VE_DNLP_RL_10, // max_contrast = 1.6250x |
42 | VE_DNLP_RL_11, // max_contrast = 1.6875x |
43 | VE_DNLP_RL_12, // max_contrast = 1.7500x |
44 | VE_DNLP_RL_13, // max_contrast = 1.8125x |
45 | VE_DNLP_RL_14, // max_contrast = 1.8750x |
46 | VE_DNLP_RL_15, // max_contrast = 1.9375x |
47 | VE_DNLP_RL_16, // max_contrast = 2.0000x |
48 | } ve_dnlp_rl_t; |
49 | |
50 | typedef enum ve_dnlp_ext_e { |
51 | VE_DNLP_EXT_00 = 0, // weak |
52 | VE_DNLP_EXT_01, |
53 | VE_DNLP_EXT_02, |
54 | VE_DNLP_EXT_03, |
55 | VE_DNLP_EXT_04, |
56 | VE_DNLP_EXT_05, |
57 | VE_DNLP_EXT_06, |
58 | VE_DNLP_EXT_07, |
59 | VE_DNLP_EXT_08, |
60 | VE_DNLP_EXT_09, |
61 | VE_DNLP_EXT_10, |
62 | VE_DNLP_EXT_11, |
63 | VE_DNLP_EXT_12, |
64 | VE_DNLP_EXT_13, |
65 | VE_DNLP_EXT_14, |
66 | VE_DNLP_EXT_15, |
67 | VE_DNLP_EXT_16, // strong |
68 | } ve_dnlp_ext_t; |
69 | |
70 | typedef struct ve_bext_s { |
71 | unsigned char en; |
72 | unsigned char start; |
73 | unsigned char slope1; |
74 | unsigned char midpt; |
75 | unsigned char slope2; |
76 | } ve_bext_t; |
77 | |
78 | typedef struct ve_dnlp_s { |
79 | unsigned int en; |
80 | enum ve_dnlp_rt_e rt; |
81 | enum ve_dnlp_rl_e rl; |
82 | enum ve_dnlp_ext_e black; |
83 | enum ve_dnlp_ext_e white; |
84 | } ve_dnlp_t; |
85 | typedef struct ve_hist_s { |
86 | unsigned long sum; |
87 | int width; |
88 | int height; |
89 | int ave; |
90 | } ve_hist_t; |
91 | /*typedef struct ve_dnlp_table_s { |
92 | unsigned int en; |
93 | unsigned int method; |
94 | unsigned int cliprate; |
95 | unsigned int lowrange; |
96 | unsigned int hghrange; |
97 | unsigned int lowalpha; |
98 | unsigned int midalpha; |
99 | unsigned int hghalpha; |
100 | } ve_dnlp_table_t;*/ |
101 | typedef struct ve_dnlp_table_s { |
102 | unsigned int en; |
103 | unsigned int method; |
104 | unsigned int cliprate; |
105 | unsigned int lowrange; |
106 | unsigned int hghrange; |
107 | unsigned int lowalpha; |
108 | unsigned int midalpha; |
109 | unsigned int hghalpha; |
110 | unsigned int adj_level; |
111 | unsigned int new_adj_level; |
112 | unsigned int new_mvreflsh; |
113 | unsigned int new_gmma_rate; |
114 | unsigned int new_lowalpha; |
115 | unsigned int new_hghalpha; |
116 | unsigned int new_sbgnbnd; |
117 | unsigned int new_sendbnd; |
118 | unsigned int new_clashBgn; |
119 | unsigned int new_clashEnd; |
120 | unsigned int new_cliprate; |
121 | unsigned int new_mtdbld_rate; |
122 | unsigned int new_blkgma_rate; |
123 | } ve_dnlp_table_t; |
124 | typedef struct ve_hsvs_s { |
125 | unsigned char en; |
126 | unsigned char peak_gain_h1; |
127 | unsigned char peak_gain_h2; |
128 | unsigned char peak_gain_h3; |
129 | unsigned char peak_gain_h4; |
130 | unsigned char peak_gain_h5; |
131 | unsigned char peak_gain_v1; |
132 | unsigned char peak_gain_v2; |
133 | unsigned char peak_gain_v3; |
134 | unsigned char peak_gain_v4; |
135 | unsigned char peak_gain_v5; |
136 | unsigned char peak_gain_v6; |
137 | unsigned char hpeak_slope1; |
138 | unsigned char hpeak_slope2; |
139 | unsigned char hpeak_thr1; |
140 | unsigned char hpeak_thr2; |
141 | unsigned char hpeak_nlp_cor_thr; |
142 | unsigned char hpeak_nlp_gain_pos; |
143 | unsigned char hpeak_nlp_gain_neg; |
144 | unsigned char vpeak_slope1; |
145 | unsigned char vpeak_slope2; |
146 | unsigned char vpeak_thr1; |
147 | unsigned char vpeak_thr2; |
148 | unsigned char vpeak_nlp_cor_thr; |
149 | unsigned char vpeak_nlp_gain_pos; |
150 | unsigned char vpeak_nlp_gain_neg; |
151 | unsigned char speak_slope1; |
152 | unsigned char speak_slope2; |
153 | unsigned char speak_thr1; |
154 | unsigned char speak_thr2; |
155 | unsigned char speak_nlp_cor_thr; |
156 | unsigned char speak_nlp_gain_pos; |
157 | unsigned char speak_nlp_gain_neg; |
158 | unsigned char peak_cor_gain; |
159 | unsigned char peak_cor_thr_l; |
160 | unsigned char peak_cor_thr_h; |
161 | unsigned char vlti_step; |
162 | unsigned char vlti_step2; |
163 | unsigned char vlti_thr; |
164 | unsigned char vlti_gain_pos; |
165 | unsigned char vlti_gain_neg; |
166 | unsigned char vlti_blend_factor; |
167 | unsigned char hlti_step; |
168 | unsigned char hlti_thr; |
169 | unsigned char hlti_gain_pos; |
170 | unsigned char hlti_gain_neg; |
171 | unsigned char hlti_blend_factor; |
172 | unsigned char vlimit_coef_h; |
173 | unsigned char vlimit_coef_l; |
174 | unsigned char hlimit_coef_h; |
175 | unsigned char hlimit_coef_l; |
176 | unsigned char cti_444_422_en; |
177 | unsigned char cti_422_444_en; |
178 | unsigned char cti_blend_factor; |
179 | unsigned char vcti_buf_en; |
180 | unsigned char vcti_buf_mode_c5l; |
181 | unsigned char vcti_filter; |
182 | unsigned char hcti_step; |
183 | unsigned char hcti_step2; |
184 | unsigned char hcti_thr; |
185 | unsigned char hcti_gain; |
186 | unsigned char hcti_mode_median; |
187 | } ve_hsvs_t; |
188 | |
189 | typedef struct ve_ccor_s { |
190 | unsigned char en; |
191 | unsigned char slope; |
192 | unsigned char thr; |
193 | } ve_ccor_t; |
194 | |
195 | typedef struct ve_benh_s { |
196 | unsigned char en; |
197 | unsigned char cb_inc; |
198 | unsigned char cr_inc; |
199 | unsigned char gain_cr; |
200 | unsigned char gain_cb4cr; |
201 | unsigned char luma_h; |
202 | unsigned char err_crp; |
203 | unsigned char err_crn; |
204 | unsigned char err_cbp; |
205 | unsigned char err_cbn; |
206 | } ve_benh_t; |
207 | |
208 | typedef struct ve_cbar_s { |
209 | unsigned char en; |
210 | unsigned char wid; |
211 | unsigned char cr; |
212 | unsigned char cb; |
213 | unsigned char y; |
214 | } ve_cbar_t; |
215 | typedef struct ve_demo_s { |
216 | unsigned char bext; |
217 | unsigned char dnlp; |
218 | unsigned char hsvs; |
219 | unsigned char ccor; |
220 | unsigned char benh; |
221 | enum ve_demo_pos_e pos; |
222 | unsigned long wid; |
223 | struct ve_cbar_s cbar; |
224 | } ve_demo_t; |
225 | |
226 | typedef struct vdo_meas_s { |
227 | //... |
228 | } vdo_meas_t; |
229 | |
230 | typedef struct ve_regmap_s { |
231 | unsigned long reg[43]; |
232 | } ve_regmap_t; |
233 | |
234 | // *************************************************************************** |
235 | // *** MACRO definitions ********** |
236 | // *************************************************************************** |
237 | |
238 | // *************************************************************************** |
239 | // *** FUNCTION definitions ********** |
240 | // *************************************************************************** |
241 | |
242 | #endif // _VE_H |
243 |