ve_regs.h 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396
  1. #ifndef _VE_REG_H
  2. #define _VE_REG_H
  3. // *****************************************************************************
  4. // ******** VIDEO ENHANCEMENT REGISTERS ********
  5. // *****************************************************************************
  6. //#define VPP_BLACKEXT_CTRL 0x1d80
  7. #define BEXT_START_BIT 24
  8. #define BEXT_START_WID 8
  9. #define BEXT_SLOPE1_BIT 16
  10. #define BEXT_SLOPE1_WID 8
  11. #define BEXT_MIDPT_BIT 8
  12. #define BEXT_MIDPT_WID 8
  13. #define BEXT_SLOPE2_BIT 0
  14. #define BEXT_SLOPE2_WID 8
  15. //#define VPP_DNLP_CTRL_00 0x1d81
  16. #define DNLP_GAMMA03_BIT 24
  17. #define DNLP_GAMMA03_WID 8
  18. #define DNLP_GAMMA02_BIT 16
  19. #define DNLP_GAMMA02_WID 8
  20. #define DNLP_GAMMA01_BIT 8
  21. #define DNLP_GAMMA01_WID 8
  22. #define DNLP_GAMMA00_BIT 0
  23. #define DNLP_GAMMA00_WID 8
  24. //#define VPP_DNLP_CTRL_01 0x1d82
  25. #define DNLP_GAMMA07_BIT 24
  26. #define DNLP_GAMMA07_WID 8
  27. #define DNLP_GAMMA06_BIT 16
  28. #define DNLP_GAMMA06_WID 8
  29. #define DNLP_GAMMA05_BIT 8
  30. #define DNLP_GAMMA05_WID 8
  31. #define DNLP_GAMMA04_BIT 0
  32. #define DNLP_GAMMA04_WID 8
  33. //#define VPP_DNLP_CTRL_02 0x1d83
  34. #define DNLP_GAMMA11_BIT 24
  35. #define DNLP_GAMMA11_WID 8
  36. #define DNLP_GAMMA10_BIT 16
  37. #define DNLP_GAMMA10_WID 8
  38. #define DNLP_GAMMA09_BIT 8
  39. #define DNLP_GAMMA09_WID 8
  40. #define DNLP_GAMMA08_BIT 0
  41. #define DNLP_GAMMA08_WID 8
  42. //#define VPP_DNLP_CTRL_03 0x1d84
  43. #define DNLP_GAMMA15_BIT 24
  44. #define DNLP_GAMMA15_WID 8
  45. #define DNLP_GAMMA14_BIT 16
  46. #define DNLP_GAMMA14_WID 8
  47. #define DNLP_GAMMA13_BIT 8
  48. #define DNLP_GAMMA13_WID 8
  49. #define DNLP_GAMMA12_BIT 0
  50. #define DNLP_GAMMA12_WID 8
  51. //#define VPP_DNLP_CTRL_04 0x1d85
  52. #define DNLP_GAMMA19_BIT 24
  53. #define DNLP_GAMMA19_WID 8
  54. #define DNLP_GAMMA18_BIT 16
  55. #define DNLP_GAMMA18_WID 8
  56. #define DNLP_GAMMA17_BIT 8
  57. #define DNLP_GAMMA17_WID 8
  58. #define DNLP_GAMMA16_BIT 0
  59. #define DNLP_GAMMA16_WID 8
  60. //#define VPP_DNLP_CTRL_05 0x1d86
  61. #define DNLP_GAMMA23_BIT 24
  62. #define DNLP_GAMMA23_WID 8
  63. #define DNLP_GAMMA22_BIT 16
  64. #define DNLP_GAMMA22_WID 8
  65. #define DNLP_GAMMA21_BIT 8
  66. #define DNLP_GAMMA21_WID 8
  67. #define DNLP_GAMMA20_BIT 0
  68. #define DNLP_GAMMA20_WID 8
  69. //#define VPP_DNLP_CTRL_06 0x1d87
  70. #define DNLP_GAMMA27_BIT 24
  71. #define DNLP_GAMMA27_WID 8
  72. #define DNLP_GAMMA26_BIT 16
  73. #define DNLP_GAMMA26_WID 8
  74. #define DNLP_GAMMA25_BIT 8
  75. #define DNLP_GAMMA25_WID 8
  76. #define DNLP_GAMMA24_BIT 0
  77. #define DNLP_GAMMA24_WID 8
  78. //#define VPP_DNLP_CTRL_07 0x1d88
  79. #define DNLP_GAMMA31_BIT 24
  80. #define DNLP_GAMMA31_WID 8
  81. #define DNLP_GAMMA30_BIT 16
  82. #define DNLP_GAMMA30_WID 8
  83. #define DNLP_GAMMA29_BIT 8
  84. #define DNLP_GAMMA29_WID 8
  85. #define DNLP_GAMMA28_BIT 0
  86. #define DNLP_GAMMA28_WID 8
  87. //#define VPP_DNLP_CTRL_08 0x1d89
  88. #define DNLP_GAMMA35_BIT 24
  89. #define DNLP_GAMMA35_WID 8
  90. #define DNLP_GAMMA34_BIT 16
  91. #define DNLP_GAMMA34_WID 8
  92. #define DNLP_GAMMA33_BIT 8
  93. #define DNLP_GAMMA33_WID 8
  94. #define DNLP_GAMMA32_BIT 0
  95. #define DNLP_GAMMA32_WID 8
  96. //#define VPP_DNLP_CTRL_09 0x1d8a
  97. #define DNLP_GAMMA39_BIT 24
  98. #define DNLP_GAMMA39_WID 8
  99. #define DNLP_GAMMA38_BIT 16
  100. #define DNLP_GAMMA38_WID 8
  101. #define DNLP_GAMMA37_BIT 8
  102. #define DNLP_GAMMA37_WID 8
  103. #define DNLP_GAMMA36_BIT 0
  104. #define DNLP_GAMMA36_WID 8
  105. //#define VPP_DNLP_CTRL_10 0x1d8b
  106. #define DNLP_GAMMA43_BIT 24
  107. #define DNLP_GAMMA43_WID 8
  108. #define DNLP_GAMMA42_BIT 16
  109. #define DNLP_GAMMA42_WID 8
  110. #define DNLP_GAMMA41_BIT 8
  111. #define DNLP_GAMMA41_WID 8
  112. #define DNLP_GAMMA40_BIT 0
  113. #define DNLP_GAMMA40_WID 8
  114. //#define VPP_DNLP_CTRL_11 0x1d8c
  115. #define DNLP_GAMMA47_BIT 24
  116. #define DNLP_GAMMA47_WID 8
  117. #define DNLP_GAMMA46_BIT 16
  118. #define DNLP_GAMMA46_WID 8
  119. #define DNLP_GAMMA45_BIT 8
  120. #define DNLP_GAMMA45_WID 8
  121. #define DNLP_GAMMA44_BIT 0
  122. #define DNLP_GAMMA44_WID 8
  123. //#define VPP_DNLP_CTRL_12 0x1d8d
  124. #define DNLP_GAMMA51_BIT 24
  125. #define DNLP_GAMMA51_WID 8
  126. #define DNLP_GAMMA50_BIT 16
  127. #define DNLP_GAMMA50_WID 8
  128. #define DNLP_GAMMA49_BIT 8
  129. #define DNLP_GAMMA49_WID 8
  130. #define DNLP_GAMMA48_BIT 0
  131. #define DNLP_GAMMA48_WID 8
  132. //#define VPP_DNLP_CTRL_13 0x1d8e
  133. #define DNLP_GAMMA55_BIT 24
  134. #define DNLP_GAMMA55_WID 8
  135. #define DNLP_GAMMA54_BIT 16
  136. #define DNLP_GAMMA54_WID 8
  137. #define DNLP_GAMMA53_BIT 8
  138. #define DNLP_GAMMA53_WID 8
  139. #define DNLP_GAMMA52_BIT 0
  140. #define DNLP_GAMMA52_WID 8
  141. //#define VPP_DNLP_CTRL_14 0x1d8f
  142. #define DNLP_GAMMA59_BIT 24
  143. #define DNLP_GAMMA59_WID 8
  144. #define DNLP_GAMMA58_BIT 16
  145. #define DNLP_GAMMA58_WID 8
  146. #define DNLP_GAMMA57_BIT 8
  147. #define DNLP_GAMMA57_WID 8
  148. #define DNLP_GAMMA56_BIT 0
  149. #define DNLP_GAMMA56_WID 8
  150. //#define VPP_DNLP_CTRL_15 0x1d90
  151. #define DNLP_GAMMA63_BIT 24
  152. #define DNLP_GAMMA63_WID 8
  153. #define DNLP_GAMMA62_BIT 16
  154. #define DNLP_GAMMA62_WID 8
  155. #define DNLP_GAMMA61_BIT 8
  156. #define DNLP_GAMMA61_WID 8
  157. #define DNLP_GAMMA60_BIT 0
  158. #define DNLP_GAMMA60_WID 8
  159. //#define VPP_PEAKING_HGAIN 0x1d91
  160. #define VLTI_STEP_BIT 28
  161. #define VLTI_STEP_WID 1
  162. #define VLTI_STEP2_BIT 27
  163. #define VLTI_STEP2_WID 1
  164. #define HLTI_STEP_BIT 25
  165. #define HLTI_STEP_WID 2
  166. #define PEAK_GAIN_H1_BIT 20
  167. #define PEAK_GAIN_H1_WID 5
  168. #define PEAK_GAIN_H2_BIT 15
  169. #define PEAK_GAIN_H2_WID 5
  170. #define PEAK_GAIN_H3_BIT 10
  171. #define PEAK_GAIN_H3_WID 5
  172. #define PEAK_GAIN_H4_BIT 5
  173. #define PEAK_GAIN_H4_WID 5
  174. #define PEAK_GAIN_H5_BIT 0
  175. #define PEAK_GAIN_H5_WID 5
  176. //#define VPP_PEAKING_VGAIN 0x1d92
  177. #define VCTI_BUF_EN_BIT 31
  178. #define VCTI_BUF_EN_WID 1
  179. #define VCTI_BUF_MODE_C5L_BIT 30
  180. #define VCTI_BUF_MODE_C5L_WID 1
  181. #define PEAK_GAIN_V1_BIT 25
  182. #define PEAK_GAIN_V1_WID 5
  183. #define PEAK_GAIN_V2_BIT 20
  184. #define PEAK_GAIN_V2_WID 5
  185. #define PEAK_GAIN_V3_BIT 15
  186. #define PEAK_GAIN_V3_WID 5
  187. #define PEAK_GAIN_V4_BIT 10
  188. #define PEAK_GAIN_V4_WID 5
  189. #define PEAK_GAIN_V5_BIT 5
  190. #define PEAK_GAIN_V5_WID 5
  191. #define PEAK_GAIN_V6_BIT 0
  192. #define PEAK_GAIN_V6_WID 5
  193. //#define VPP_PEAKING_NLP_1 0x1d93
  194. #define HPEAK_SLOPE1_BIT 26
  195. #define HPEAK_SLOPE1_WID 6
  196. #define HPEAK_SLOPE2_BIT 20
  197. #define HPEAK_SLOPE2_WID 6
  198. #define HPEAK_THR1_BIT 12
  199. #define HPEAK_THR1_WID 8
  200. #define VPEAK_SLOPE1_BIT 6
  201. #define VPEAK_SLOPE1_WID 6
  202. #define VPEAK_SLOPE2_BIT 0
  203. #define VPEAK_SLOPE2_WID 6
  204. //#define VPP_PEAKING_NLP_2 0x1d94
  205. #define HPEAK_THR2_BIT 24
  206. #define HPEAK_THR2_WID 8
  207. #define HPEAK_NLP_COR_THR_BIT 16
  208. #define HPEAK_NLP_COR_THR_WID 8
  209. #define HPEAK_NLP_GAIN_POS_BIT 8
  210. #define HPEAK_NLP_GAIN_POS_WID 8
  211. #define HPEAK_NLP_GAIN_NEG_BIT 0
  212. #define HPEAK_NLP_GAIN_NEG_WID 8
  213. //#define VPP_PEAKING_NLP_3 0x1d95
  214. #define VPEAK_THR1_BIT 24
  215. #define VPEAK_THR1_WID 8
  216. #define SPEAK_SLOPE1_BIT 18
  217. #define SPEAK_SLOPE1_WID 6
  218. #define SPEAK_SLOPE2_BIT 12
  219. #define SPEAK_SLOPE2_WID 6
  220. #define SPEAK_THR1_BIT 4
  221. #define SPEAK_THR1_WID 8
  222. #define PEAK_COR_GAIN_BIT 0
  223. #define PEAK_COR_GAIN_WID 4
  224. //#define VPP_PEAKING_NLP_4 0x1d96
  225. #define VPEAK_THR2_BIT 24
  226. #define VPEAK_THR2_WID 8
  227. #define VPEAK_NLP_COR_THR_BIT 16
  228. #define VPEAK_NLP_COR_THR_WID 8
  229. #define VPEAK_NLP_GAIN_POS_BIT 8
  230. #define VPEAK_NLP_GAIN_POS_WID 8
  231. #define VPEAK_NLP_GAIN_NEG_BIT 0
  232. #define VPEAK_NLP_GAIN_NEG_WID 8
  233. //#define VPP_PEAKING_NLP_5 0x1d97
  234. #define SPEAK_THR2_BIT 24
  235. #define SPEAK_THR2_WID 8
  236. #define SPEAK_NLP_COR_THR_BIT 16
  237. #define SPEAK_NLP_COR_THR_WID 8
  238. #define SPEAK_NLP_GAIN_POS_BIT 8
  239. #define SPEAK_NLP_GAIN_POS_WID 8
  240. #define SPEAK_NLP_GAIN_NEG_BIT 0
  241. #define SPEAK_NLP_GAIN_NEG_WID 8
  242. //#define VPP_HSVS_LIMIT 0x1d98
  243. #define PEAK_COR_THR_L_BIT 24
  244. #define PEAK_COR_THR_L_WID 8
  245. #define PEAK_COR_THR_H_BIT 16
  246. #define PEAK_COR_THR_H_WID 8
  247. #define VLIMIT_COEF_H_BIT 12
  248. #define VLIMIT_COEF_H_WID 4
  249. #define VLIMIT_COEF_L_BIT 8
  250. #define VLIMIT_COEF_L_WID 4
  251. #define HLIMIT_COEF_H_BIT 4
  252. #define HLIMIT_COEF_H_WID 4
  253. #define HLIMIT_COEF_L_BIT 0
  254. #define HLIMIT_COEF_L_WID 4
  255. //#define VPP_VLTI_CTRL 0x1d99
  256. #define VLTI_GAIN_NEG_BIT 24
  257. #define VLTI_GAIN_NEG_WID 8
  258. #define VLTI_GAIN_POS_BIT 16
  259. #define VLTI_GAIN_POS_WID 8
  260. #define VLTI_THR_BIT 8
  261. #define VLTI_THR_WID 8
  262. #define VLTI_BLEND_FACTOR_BIT 0
  263. #define VLTI_BLEND_FACTOR_WID 8
  264. //#define VPP_HLTI_CTRL 0x1d9a
  265. #define HLTI_GAIN_NEG_BIT 24
  266. #define HLTI_GAIN_NEG_WID 8
  267. #define HLTI_GAIN_POS_BIT 16
  268. #define HLTI_GAIN_POS_WID 8
  269. #define HLTI_THR_BIT 8
  270. #define HLTI_THR_WID 8
  271. #define HLTI_BLEND_FACTOR_BIT 0
  272. #define HLTI_BLEND_FACTOR_WID 8
  273. //#define VPP_CTI_CTRL 0x1d9b
  274. #define CTI_C444TO422_EN_BIT 30
  275. #define CTI_C444TO422_EN_WID 1
  276. #define VCTI_FILTER_BIT 28
  277. #define VCTI_FILTER_WID 2
  278. #define CTI_C422TO444_EN_BIT 27
  279. #define CTI_C422TO444_EN_WID 1
  280. #define HCTI_STEP2_BIT 24
  281. #define HCTI_STEP2_WID 3
  282. #define HCTI_STEP_BIT 21
  283. #define HCTI_STEP_WID 3
  284. #define CTI_BLEND_FACTOR_BIT 16
  285. #define CTI_BLEND_FACTOR_WID 5
  286. #define HCTI_MODE_MEDIAN_BIT 15
  287. #define HCTI_MODE_MEDIAN_WID 1
  288. #define HCTI_THR_BIT 8
  289. #define HCTI_THR_WID 7
  290. #define HCTI_GAIN_BIT 0
  291. #define HCTI_GAIN_WID 8
  292. //#define VPP_BLUE_STRETCH_1 0x1d9c
  293. #define BENH_CB_INC_BIT 29
  294. #define BENH_CB_INC_WID 1
  295. #define BENH_CR_INC_BIT 28
  296. #define BENH_CR_INC_WID 1
  297. #define BENH_ERR_CRP_INV_H_BIT 27
  298. #define BENH_ERR_CRP_INV_H_WID 1
  299. #define BENH_ERR_CRN_INV_H_BIT 26
  300. #define BENH_ERR_CRN_INV_H_WID 1
  301. #define BENH_ERR_CBP_INV_H_BIT 25
  302. #define BENH_ERR_CBP_INV_H_WID 1
  303. #define BENH_ERR_CBN_INV_H_BIT 24
  304. #define BENH_ERR_CBN_INV_H_WID 1
  305. #define BENH_GAIN_CR_BIT 16
  306. #define BENH_GAIN_CR_WID 8
  307. #define BENH_GAIN_CB4CR_BIT 8
  308. #define BENH_GAIN_CB4CR_WID 8
  309. #define BENH_LUMA_H_BIT 0
  310. #define BENH_LUMA_H_WID 8
  311. //#define VPP_BLUE_STRETCH_2 0x1d9d
  312. #define BENH_ERR_CRP_BIT 27
  313. #define BENH_ERR_CRP_WID 5
  314. #define BENH_ERR_CRP_INV_L_BIT 16
  315. #define BENH_ERR_CRP_INV_L_WID 11
  316. #define BENH_ERR_CRN_BIT 11
  317. #define BENH_ERR_CRN_WID 5
  318. #define BENH_ERR_CRN_INV_L_BIT 0
  319. #define BENH_ERR_CRN_INV_L_WID 11
  320. //#define VPP_BLUE_STRETCH_3 0x1d9e
  321. #define BENH_ERR_CBP_BIT 27
  322. #define BENH_ERR_CBP_WID 5
  323. #define BENH_ERR_CBP_INV_L_BIT 16
  324. #define BENH_ERR_CBP_INV_L_WID 11
  325. #define BENH_ERR_CBN_BIT 11
  326. #define BENH_ERR_CBN_WID 5
  327. #define BENH_ERR_CBN_INV_L_BIT 0
  328. #define BENH_ERR_CBN_INV_L_WID 11
  329. //#define VPP_CCORING_CTRL 0x1da0
  330. #define CCOR_THR_BIT 8
  331. #define CCOR_THR_WID 8
  332. #define CCOR_SLOPE_BIT 0
  333. #define CCOR_SLOPE_WID 4
  334. //#define VPP_VE_ENABLE_CTRL 0x1da1
  335. #define DEMO_CCOR_BIT 20
  336. #define DEMO_CCOR_WID 1
  337. #define DEMO_BEXT_BIT 19
  338. #define DEMO_BEXT_WID 1
  339. #define DEMO_DNLP_BIT 18
  340. #define DEMO_DNLP_WID 1
  341. #define DEMO_HSVS_BIT 17
  342. #define DEMO_HSVS_WID 1
  343. #define DEMO_BENH_BIT 16
  344. #define DEMO_BENH_WID 1
  345. #define VE_DEMO_POS_BIT 15
  346. #define VE_DEMO_POS_WID 1
  347. #define CCOR_EN_BIT 4
  348. #define CCOR_EN_WID 1
  349. #define BEXT_EN_BIT 3
  350. #define BEXT_EN_WID 1
  351. #define DNLP_EN_BIT 2
  352. #define DNLP_EN_WID 1
  353. #define HSVS_EN_BIT 1
  354. #define HSVS_EN_WID 1
  355. #define BENH_EN_BIT 0
  356. #define BENH_EN_WID 1
  357. //#define VPP_VE_DEMO_LEFT_SCREEN_WIDTH 0x1da2
  358. #define DEMO_WID_BIT 0
  359. #define DEMO_WID_WID 12
  360. #endif // _VE_REG_H