| 1 | /*************************************************************************** |
|---|
| 2 | * (c)2007-2011 Broadcom Corporation |
|---|
| 3 | * |
|---|
| 4 | * This program is the proprietary software of Broadcom Corporation and/or its licensors, |
|---|
| 5 | * and may only be used, duplicated, modified or distributed pursuant to the terms and |
|---|
| 6 | * conditions of a separate, written license agreement executed between you and Broadcom |
|---|
| 7 | * (an "Authorized License"). Except as set forth in an Authorized License, Broadcom grants |
|---|
| 8 | * no license (express or implied), right to use, or waiver of any kind with respect to the |
|---|
| 9 | * Software, and Broadcom expressly reserves all rights in and to the Software and all |
|---|
| 10 | * intellectual property rights therein. IF YOU HAVE NO AUTHORIZED LICENSE, THEN YOU |
|---|
| 11 | * HAVE NO RIGHT TO USE THIS SOFTWARE IN ANY WAY, AND SHOULD IMMEDIATELY |
|---|
| 12 | * NOTIFY BROADCOM AND DISCONTINUE ALL USE OF THE SOFTWARE. |
|---|
| 13 | * |
|---|
| 14 | * Except as expressly set forth in the Authorized License, |
|---|
| 15 | * |
|---|
| 16 | * 1. This program, including its structure, sequence and organization, constitutes the valuable trade |
|---|
| 17 | * secrets of Broadcom, and you shall use all reasonable efforts to protect the confidentiality thereof, |
|---|
| 18 | * and to use this information only in connection with your use of Broadcom integrated circuit products. |
|---|
| 19 | * |
|---|
| 20 | * 2. TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS PROVIDED "AS IS" |
|---|
| 21 | * AND WITH ALL FAULTS AND BROADCOM MAKES NO PROMISES, REPRESENTATIONS OR |
|---|
| 22 | * WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY, OR OTHERWISE, WITH RESPECT TO |
|---|
| 23 | * THE SOFTWARE. BROADCOM SPECIFICALLY DISCLAIMS ANY AND ALL IMPLIED WARRANTIES |
|---|
| 24 | * OF TITLE, MERCHANTABILITY, NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, |
|---|
| 25 | * LACK OF VIRUSES, ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION |
|---|
| 26 | * OR CORRESPONDENCE TO DESCRIPTION. YOU ASSUME THE ENTIRE RISK ARISING OUT OF |
|---|
| 27 | * USE OR PERFORMANCE OF THE SOFTWARE. |
|---|
| 28 | * |
|---|
| 29 | * 3. TO THE MAXIMUM EXTENT PERMITTED BY LAW, IN NO EVENT SHALL BROADCOM OR ITS |
|---|
| 30 | * LICENSORS BE LIABLE FOR (i) CONSEQUENTIAL, INCIDENTAL, SPECIAL, INDIRECT, OR |
|---|
| 31 | * EXEMPLARY DAMAGES WHATSOEVER ARISING OUT OF OR IN ANY WAY RELATING TO YOUR |
|---|
| 32 | * USE OF OR INABILITY TO USE THE SOFTWARE EVEN IF BROADCOM HAS BEEN ADVISED OF |
|---|
| 33 | * THE POSSIBILITY OF SUCH DAMAGES; OR (ii) ANY AMOUNT IN EXCESS OF THE AMOUNT |
|---|
| 34 | * ACTUALLY PAID FOR THE SOFTWARE ITSELF OR U.S. $1, WHICHEVER IS GREATER. THESE |
|---|
| 35 | * LIMITATIONS SHALL APPLY NOTWITHSTANDING ANY FAILURE OF ESSENTIAL PURPOSE OF |
|---|
| 36 | * ANY LIMITED REMEDY. |
|---|
| 37 | * |
|---|
| 38 | * $brcm_Workfile: nexus_video_adj.h $ |
|---|
| 39 | * $brcm_Revision: 23 $ |
|---|
| 40 | * $brcm_Date: 3/22/11 9:29a $ |
|---|
| 41 | * |
|---|
| 42 | * Module Description: |
|---|
| 43 | * |
|---|
| 44 | * Revision History: |
|---|
| 45 | * |
|---|
| 46 | * $brcm_Log: /nexus/modules/display/7400/include/nexus_video_adj.h $ |
|---|
| 47 | * |
|---|
| 48 | * 23 3/22/11 9:29a erickson |
|---|
| 49 | * SW7405-5201: update comments on NEXUS_ScalerCaptureBias |
|---|
| 50 | * |
|---|
| 51 | * 22 3/2/11 3:13p erickson |
|---|
| 52 | * SW7420-1285: fix null_allowed attr |
|---|
| 53 | * |
|---|
| 54 | * 21 12/14/10 3:18p erickson |
|---|
| 55 | * SW7420-1285: add null_allowed attribute |
|---|
| 56 | * |
|---|
| 57 | * 20 8/27/10 8:59a erickson |
|---|
| 58 | * SW7420-965: sync up comments with 3548 nexus_video_adj.h |
|---|
| 59 | * |
|---|
| 60 | * 19 8/27/10 8:53a erickson |
|---|
| 61 | * SW7420-965: add two more NEXUS_VideoWindowGameMode enums |
|---|
| 62 | * |
|---|
| 63 | * 18 8/26/10 3:32p erickson |
|---|
| 64 | * SW7420-965: add NEXUS_VideoWindowGameMode_e4Fields_2Delay |
|---|
| 65 | * |
|---|
| 66 | * 17 5/7/10 4:06p erickson |
|---|
| 67 | * SWDEPRECATED-2425: fix comments on |
|---|
| 68 | * NEXUS_VideoWindowFilterSettings.level |
|---|
| 69 | * |
|---|
| 70 | * 16 4/1/10 2:59p erickson |
|---|
| 71 | * SW7405-4074: add usage comments for NEXUS_VideoWindowGameMode |
|---|
| 72 | * |
|---|
| 73 | * 15 2/10/10 2:34p erickson |
|---|
| 74 | * SW7405-3829: add NEXUS_VideoWindowMadSettings.shrinkWidth |
|---|
| 75 | * |
|---|
| 76 | * 14 10/29/08 11:38a erickson |
|---|
| 77 | * PR48028: added deringing and dejagging options to |
|---|
| 78 | * NEXUS_VideoWindowScalerSettings |
|---|
| 79 | * |
|---|
| 80 | * 13 10/22/08 5:24p erickson |
|---|
| 81 | * PR48023: update comments |
|---|
| 82 | * |
|---|
| 83 | * 12 9/25/08 9:45a erickson |
|---|
| 84 | * PR47113: replace NEXUS_VideoWindow_SetScalerCoefficientIndex with |
|---|
| 85 | * NEXUS_VideoWindow_SetCoefficientIndexSettings |
|---|
| 86 | * |
|---|
| 87 | * 11 9/16/08 5:17p erickson |
|---|
| 88 | * PR46967: fix naming of NEXUS_VideoWindowScalerSettings |
|---|
| 89 | * |
|---|
| 90 | * 10 7/17/08 9:34a erickson |
|---|
| 91 | * PR44764: update for BVDC_Window_SetBandwidthEquationParams api change |
|---|
| 92 | * |
|---|
| 93 | * 9 6/18/08 10:04a erickson |
|---|
| 94 | * PR43617: extended NEXUS_VideoWindowScalerSettings with bandwidth equation |
|---|
| 95 | * params |
|---|
| 96 | * |
|---|
| 97 | * 8 3/27/08 9:49a erickson |
|---|
| 98 | * PR40950: remove unused variables |
|---|
| 99 | * |
|---|
| 100 | * 7 3/26/08 2:36p erickson |
|---|
| 101 | * PR40950: set custom ANR/DNR data in custom function |
|---|
| 102 | * |
|---|
| 103 | * 6 3/26/08 12:54p erickson |
|---|
| 104 | * PR40567: add MAD and ANR pixel format |
|---|
| 105 | * |
|---|
| 106 | * PR40567/1 3/26/08 4:19p xhuang |
|---|
| 107 | * PR40567:add pixel format set in Nexus |
|---|
| 108 | * |
|---|
| 109 | * 5 1/28/08 1:07p erickson |
|---|
| 110 | * PR35457: add change notice |
|---|
| 111 | * |
|---|
| 112 | * 4 1/25/08 9:42a erickson |
|---|
| 113 | * PR39003: adapt to latest VDC |
|---|
| 114 | * |
|---|
| 115 | * PR39003/1 1/25/08 3:06p xhuang |
|---|
| 116 | * PR39003:update MAD game mode define |
|---|
| 117 | * |
|---|
| 118 | * 3 1/23/08 8:37p vobadm |
|---|
| 119 | * PR35457: update docs |
|---|
| 120 | * |
|---|
| 121 | * 2 1/23/08 5:16p erickson |
|---|
| 122 | * PR35457: update docs |
|---|
| 123 | * |
|---|
| 124 | * 1 1/18/08 2:20p jgarrett |
|---|
| 125 | * PR 38808: Merging to main branch |
|---|
| 126 | * |
|---|
| 127 | * Nexus_Devel/13 1/8/08 3:52p erickson |
|---|
| 128 | * PR36159: rename DNR/ANR/MAD functions to be VideoWindow |
|---|
| 129 | * |
|---|
| 130 | * Nexus_Devel/12 1/8/08 10:57a erickson |
|---|
| 131 | * PR36159: refactor some 3563 Display API's |
|---|
| 132 | * |
|---|
| 133 | * Nexus_Devel/11 12/18/07 1:35p erickson |
|---|
| 134 | * PR38213: analog video input rework |
|---|
| 135 | * |
|---|
| 136 | * Nexus_Devel/10 11/30/07 10:52a erickson |
|---|
| 137 | * PR35457: api update |
|---|
| 138 | * |
|---|
| 139 | **************************************************************************/ |
|---|
| 140 | #ifndef NEXUS_VIDEO_ADJUST_H__ |
|---|
| 141 | #define NEXUS_VIDEO_ADJUST_H__ |
|---|
| 142 | |
|---|
| 143 | #include "nexus_types.h" |
|---|
| 144 | #include "nexus_display_types.h" |
|---|
| 145 | |
|---|
| 146 | #ifdef __cplusplus |
|---|
| 147 | extern "C" { |
|---|
| 148 | #endif |
|---|
| 149 | |
|---|
| 150 | /*=* |
|---|
| 151 | The Video Adjustment interface allows manipulation of BVN-middle processing units. |
|---|
| 152 | |
|---|
| 153 | NOTE: This API will be revised for BCM3548. The functions and structures will change |
|---|
| 154 | in future Nexus releases. |
|---|
| 155 | **/ |
|---|
| 156 | |
|---|
| 157 | /** |
|---|
| 158 | Summary: |
|---|
| 159 | Mode used in NEXUS_VideoWindowFilterSettings |
|---|
| 160 | **/ |
|---|
| 161 | typedef enum NEXUS_VideoWindowFilterMode |
|---|
| 162 | { |
|---|
| 163 | NEXUS_VideoWindowFilterMode_eDisable = 0, |
|---|
| 164 | NEXUS_VideoWindowFilterMode_eBypass, |
|---|
| 165 | NEXUS_VideoWindowFilterMode_eEnable, |
|---|
| 166 | NEXUS_VideoWindowFilterMode_eMax |
|---|
| 167 | } NEXUS_VideoWindowFilterMode; |
|---|
| 168 | |
|---|
| 169 | /** |
|---|
| 170 | Summary: |
|---|
| 171 | Filter settings used in NEXUS_VideoWindowDnrSettings and NEXUS_VideoWindowAnrSettings. |
|---|
| 172 | **/ |
|---|
| 173 | typedef struct NEXUS_VideoWindowFilterSettings |
|---|
| 174 | { |
|---|
| 175 | NEXUS_VideoWindowFilterMode mode; /* mode of noise reduction */ |
|---|
| 176 | int level; /* level of noise reduction, valid range -100 ... 2^31 */ |
|---|
| 177 | } NEXUS_VideoWindowFilterSettings; |
|---|
| 178 | |
|---|
| 179 | /** |
|---|
| 180 | Summary: |
|---|
| 181 | Digital Noise Reduction (DNR) settings |
|---|
| 182 | |
|---|
| 183 | Description: |
|---|
| 184 | See BVDC_Dnr_Settings for detailed information |
|---|
| 185 | **/ |
|---|
| 186 | typedef struct NEXUS_VideoWindowDnrSettings |
|---|
| 187 | { |
|---|
| 188 | NEXUS_VideoWindowFilterSettings mnr; /* Mosquito Noise Reduction. See BVDC_Dnr_Settings for mnr.level range. */ |
|---|
| 189 | NEXUS_VideoWindowFilterSettings bnr; /* Block Noise Reduction. See BVDC_Dnr_Settings for bnr.level range. */ |
|---|
| 190 | NEXUS_VideoWindowFilterSettings dcr; /* Digital Contour Reduction. See BVDC_Dnr_Settings for dcr.level range. */ |
|---|
| 191 | unsigned qp; /* non zero value is used to force constant QP (0 is default and used to derive QP from the decoded stream) */ |
|---|
| 192 | } NEXUS_VideoWindowDnrSettings; |
|---|
| 193 | |
|---|
| 194 | /** |
|---|
| 195 | Summary: |
|---|
| 196 | Analog Noise Reduction (ANR) settings |
|---|
| 197 | |
|---|
| 198 | Description: |
|---|
| 199 | anr.level is used for user adjustment to S/N db number. |
|---|
| 200 | If S/N is around 60 db, the video signal is very clean and ANR |
|---|
| 201 | will be configured to perform very little filtering. When S/N db |
|---|
| 202 | number become smaller, the video signal is more noisy and ANR will |
|---|
| 203 | be configured to perform stronger filtering. As it reaches to |
|---|
| 204 | about 25 db, ANR filtering reaches the strongest. |
|---|
| 205 | **/ |
|---|
| 206 | typedef struct NEXUS_VideoWindowAnrSettings |
|---|
| 207 | { |
|---|
| 208 | NEXUS_VideoWindowFilterSettings anr; /* Analog Noise Reduction */ |
|---|
| 209 | |
|---|
| 210 | NEXUS_PixelFormat pixelFormat; /* pixel format of ANR buffer */ |
|---|
| 211 | } NEXUS_VideoWindowAnrSettings; |
|---|
| 212 | |
|---|
| 213 | /** |
|---|
| 214 | Summary: |
|---|
| 215 | MAD game mode options |
|---|
| 216 | |
|---|
| 217 | Description: |
|---|
| 218 | Used in NEXUS_VideoWindowMadSettings. Not related to NEXUS_VideoWindowGameModeDelay. |
|---|
| 219 | |
|---|
| 220 | For pause or frame advance on multi-display systems, the delay introduced by MAD can cause noticeably different pictures |
|---|
| 221 | to appear on each display. To eliminate this, choose one of the "ForceSpatial" options below. |
|---|
| 222 | By default, nexus will configure MAD to allocate 5 fields for MAD (worst case), so we recommend you use |
|---|
| 223 | NEXUS_VideoWindowGameMode_e5Fields_ForceSpatial. |
|---|
| 224 | **/ |
|---|
| 225 | typedef enum NEXUS_VideoWindowGameMode |
|---|
| 226 | { |
|---|
| 227 | NEXUS_VideoWindowGameMode_eOff, /* Disable MAD Game Mode */ |
|---|
| 228 | NEXUS_VideoWindowGameMode_e5Fields_2Delay, /* MAD Game Mode 5 Active Pixel Fields, 2 field delay */ |
|---|
| 229 | NEXUS_VideoWindowGameMode_e5Fields_1Delay, /* MAD Game Mode 5 Active Pixel Fields, 1 field delay */ |
|---|
| 230 | NEXUS_VideoWindowGameMode_e5Fields_0Delay, /* Mad Game Mode 5 Active Pixel Fields, 0 Field Delay */ |
|---|
| 231 | NEXUS_VideoWindowGameMode_e5Fields_ForceSpatial, /* Mad Game Mode 5 Active Pixel Fields, 0 Field Delay, Spatial Only */ |
|---|
| 232 | NEXUS_VideoWindowGameMode_e4Fields_2Delay, /* Mad Game Mode 4 Active Pixel Fields, 2 Field Delay */ |
|---|
| 233 | NEXUS_VideoWindowGameMode_e4Fields_1Delay, /* Mad Game Mode 4 Active Pixel Fields, 1 Field Delay */ |
|---|
| 234 | NEXUS_VideoWindowGameMode_e4Fields_0Delay, /* Mad Game Mode 4 Active Pixel Fields, 0 Field Delay */ |
|---|
| 235 | NEXUS_VideoWindowGameMode_e4Fields_ForceSpatial, /* Mad Game Mode 4 Active Pixel Fields, 0 Field Delay, Spatial Only */ |
|---|
| 236 | NEXUS_VideoWindowGameMode_e3Fields_2Delay, /* Mad Game Mode 3 Active Pixel Fields, 2 Field Delay */ |
|---|
| 237 | NEXUS_VideoWindowGameMode_e3Fields_1Delay, /* Mad Game Mode 3 Active Pixel Fields, 1 Field Delay */ |
|---|
| 238 | NEXUS_VideoWindowGameMode_e3Fields_0Delay, /* Mad Game Mode 3 Active Pixel Fields, 0 Field Delay */ |
|---|
| 239 | NEXUS_VideoWindowGameMode_e3Fields_ForceSpatial, /* Mad Game Mode 3 Active Pixel Fields, 0 Field Delay, Spatial Only */ |
|---|
| 240 | NEXUS_VideoWindowGameMode_eMax |
|---|
| 241 | } NEXUS_VideoWindowGameMode; |
|---|
| 242 | |
|---|
| 243 | /** |
|---|
| 244 | Summary: |
|---|
| 245 | Multi-buffering game delay mode settings |
|---|
| 246 | |
|---|
| 247 | Description: |
|---|
| 248 | Used in NEXUS_VideoWindow_SetGameModeDelay |
|---|
| 249 | |
|---|
| 250 | The game mode delay control can place the sync-slipped window's multi- |
|---|
| 251 | buffer playback pointer to a target offset relative to its capture |
|---|
| 252 | pointer to achieve smaller multi-buffer delay and faster game response. |
|---|
| 253 | |
|---|
| 254 | Note, to make sure the game mode delay control converges and stablize, |
|---|
| 255 | before enabling game mode delay control function, user should make sure |
|---|
| 256 | the followings: |
|---|
| 257 | |
|---|
| 258 | 1) make the window's display track a DPCR timebase; |
|---|
| 259 | 2) program the DPCR timebase to lock the window's source rate; |
|---|
| 260 | |
|---|
| 261 | Also note, |
|---|
| 262 | |
|---|
| 263 | - This function is currently meant for the DTV application with |
|---|
| 264 | DVO panel output; analog output might cause TV rolling or loss of sync |
|---|
| 265 | during adjustment; analog and digital outputs of the same display cannot |
|---|
| 266 | simultaneously turn on if a window enables game mode; |
|---|
| 267 | - A display can only have one window with game mode delay |
|---|
| 268 | control enabled. |
|---|
| 269 | - Only sync-slipped window can have this feature. |
|---|
| 270 | |
|---|
| 271 | This is not related to MAD game mode. See NEXUS_VideoWindowMadSettings.gameMode for MAD game mode. |
|---|
| 272 | **/ |
|---|
| 273 | typedef struct NEXUS_VideoWindowGameModeDelay |
|---|
| 274 | { |
|---|
| 275 | bool enable; /* Enable the feature; default OFF; if there is significant |
|---|
| 276 | rate gap between source and display, like 50->60, VDC will |
|---|
| 277 | internally disable it */ |
|---|
| 278 | bool forceCoarseTrack; /* Force coarse tracking of non-standard source refresh |
|---|
| 279 | rate for game mode display; |
|---|
| 280 | when this flag is turned on, display can track the source |
|---|
| 281 | rate within +-0.3% variance of the nominal value. |
|---|
| 282 | When this flag is turned off, VDC may internally switch |
|---|
| 283 | between fine track and coarse track: if source |
|---|
| 284 | format is PC format, or window master frame rate tracking |
|---|
| 285 | is off, VDC will still use coarse adjustment anyhow. So this |
|---|
| 286 | flag is mainly an override for TV input rate way off from |
|---|
| 287 | its nominal value; default OFF */ |
|---|
| 288 | uint32_t bufferDelayTarget; /* bufferDelayTarget - This is the desired difference (in usecs) between |
|---|
| 289 | source VSYNC and the display VSYNC at the capture buffer*/ |
|---|
| 290 | uint32_t bufferDelayTolerance; /* This is the tolerance from the center as defined by |
|---|
| 291 | bufferDelayTarget. This is in usecs.*/ |
|---|
| 292 | } NEXUS_VideoWindowGameModeDelay; |
|---|
| 293 | |
|---|
| 294 | /** |
|---|
| 295 | Summary: |
|---|
| 296 | Motion Adaptive Deinterlacer (MAD) settings |
|---|
| 297 | **/ |
|---|
| 298 | typedef struct NEXUS_VideoWindowMadSettings |
|---|
| 299 | { |
|---|
| 300 | bool deinterlace; /* If true, MAD is allowed to be used if available and appropriate. */ |
|---|
| 301 | bool enable32Pulldown; /* enable or disable 3:2 pulldown */ |
|---|
| 302 | bool enable22Pulldown; /* enable or disable 2:2 pulldown */ |
|---|
| 303 | NEXUS_VideoWindowGameMode gameMode; /* Include game mode */ |
|---|
| 304 | NEXUS_PixelFormat pixelFormat; /* pixel format of MAD buffer */ |
|---|
| 305 | bool shrinkWidth; /* Internally scale down the width of the input source so that we can deinterlace a source whose width exceeds |
|---|
| 306 | the MAD HW limitation. This sacrifices horizontal resolution and requires additional memory allocation and bandwidth. |
|---|
| 307 | Ideally, this setting should be applied before calling NEXUS_VideoWindow_AddInput. Otherwise, it will cause a momentary black frame. */ |
|---|
| 308 | } NEXUS_VideoWindowMadSettings; |
|---|
| 309 | |
|---|
| 310 | /** |
|---|
| 311 | Summary: |
|---|
| 312 | SCL/CAP bias for NEXUS_VideoWindowScalerSettings.bandwidthEquationParams |
|---|
| 313 | |
|---|
| 314 | Description: |
|---|
| 315 | When configuring the BVN, VDC will often require both a scaler (SCL) and capture (CAP) block. |
|---|
| 316 | BVN bandwidth considerations require a certain order, either CAP->SCL or SCL->CAP. |
|---|
| 317 | In eAuto mode, this is calculated automatically. |
|---|
| 318 | |
|---|
| 319 | When doing a continuous resize of a video window, you will see a "black flash" when the eAuto calculation |
|---|
| 320 | switches from one mode to another. This black flash is caused by a BVN reconfig, which is needed to switch |
|---|
| 321 | the order. |
|---|
| 322 | |
|---|
| 323 | If you want to avoid the black flash, you can fix the bias to be always either SCL->CAP or CAP->SCL. |
|---|
| 324 | However, this selection will require an RTS analysis and possibly new RTS settings for the BVN. |
|---|
| 325 | Unless you perform this analysis, you should leave the bias at eAuto. |
|---|
| 326 | |
|---|
| 327 | See BVDC_Window_SetBandwidthEquationParams for more documentation. |
|---|
| 328 | **/ |
|---|
| 329 | typedef enum NEXUS_ScalerCaptureBias |
|---|
| 330 | { |
|---|
| 331 | NEXUS_ScalerCaptureBias_eAuto = 0, /* dynamically switch between SCL->CAP and CAP->SCL */ |
|---|
| 332 | NEXUS_ScalerCaptureBias_eScalerBeforeCapture, /* SCL->CAP */ |
|---|
| 333 | NEXUS_ScalerCaptureBias_eScalerAfterCapture /* CAP->SCL */ |
|---|
| 334 | } NEXUS_ScalerCaptureBias; |
|---|
| 335 | |
|---|
| 336 | |
|---|
| 337 | /** |
|---|
| 338 | Summary: |
|---|
| 339 | Scaler settings |
|---|
| 340 | **/ |
|---|
| 341 | typedef struct NEXUS_VideoWindowScalerSettings |
|---|
| 342 | { |
|---|
| 343 | bool nonLinearScaling; /* Set true to enable non-linear scaling. */ |
|---|
| 344 | uint32_t nonLinearSourceWidth; /* Applied if nonLinearScaling is true */ |
|---|
| 345 | uint32_t nonLinearScalerOutWidth; /* Applied if nonLinearScaling is true */ |
|---|
| 346 | |
|---|
| 347 | /* RTS settings - applies even for linear scaling */ |
|---|
| 348 | struct { |
|---|
| 349 | NEXUS_ScalerCaptureBias bias; |
|---|
| 350 | uint32_t delta; /* tolerance for NEXUS_ScalerCaptureBias, in units of 1/10% */ |
|---|
| 351 | } bandwidthEquationParams; |
|---|
| 352 | |
|---|
| 353 | bool verticalDejagging; /* set true to enable, defaults false */ |
|---|
| 354 | bool horizontalLumaDeringing; /* set true to enable, defaults true */ |
|---|
| 355 | bool verticalLumaDeringing; /* set true to enable, defaults true */ |
|---|
| 356 | bool horizontalChromaDeringing; /* set true to enable, defaults true */ |
|---|
| 357 | bool verticalChromaDeringing; /* set true to enable, defaults true */ |
|---|
| 358 | } NEXUS_VideoWindowScalerSettings; |
|---|
| 359 | |
|---|
| 360 | /* Deprecated name */ |
|---|
| 361 | #define NEXUS_VideoWindowSclSettings NEXUS_VideoWindowScalerSettings |
|---|
| 362 | |
|---|
| 363 | /** |
|---|
| 364 | Summary: |
|---|
| 365 | Get current DNR settings |
|---|
| 366 | **/ |
|---|
| 367 | void NEXUS_VideoWindow_GetDnrSettings( |
|---|
| 368 | NEXUS_VideoWindowHandle window, |
|---|
| 369 | NEXUS_VideoWindowDnrSettings *pSettings /* [out] */ |
|---|
| 370 | ); |
|---|
| 371 | |
|---|
| 372 | /** |
|---|
| 373 | Summary: |
|---|
| 374 | Set new DNR settings |
|---|
| 375 | |
|---|
| 376 | Description: |
|---|
| 377 | This function maps to BVDC_Source_SetDnrConfiguration. |
|---|
| 378 | You can find additional documentation in bvdc.h for this function. |
|---|
| 379 | **/ |
|---|
| 380 | NEXUS_Error NEXUS_VideoWindow_SetDnrSettings( |
|---|
| 381 | NEXUS_VideoWindowHandle window, |
|---|
| 382 | const NEXUS_VideoWindowDnrSettings *pSettings |
|---|
| 383 | ); |
|---|
| 384 | |
|---|
| 385 | /** |
|---|
| 386 | Summary: |
|---|
| 387 | Set new DNR settings along with custom data for DNR processing |
|---|
| 388 | |
|---|
| 389 | Description: |
|---|
| 390 | The format of the additional data is private. |
|---|
| 391 | **/ |
|---|
| 392 | NEXUS_Error NEXUS_VideoWindow_SetCustomDnrSettings( |
|---|
| 393 | NEXUS_VideoWindowHandle window, |
|---|
| 394 | const NEXUS_VideoWindowDnrSettings *pSettings, |
|---|
| 395 | const uint8_t *pCustomData, /* attr{null_allowed=y;nelem=numEntries} additional data */ |
|---|
| 396 | unsigned numEntries |
|---|
| 397 | ); |
|---|
| 398 | |
|---|
| 399 | /** |
|---|
| 400 | Summary: |
|---|
| 401 | Get current ANR settings |
|---|
| 402 | **/ |
|---|
| 403 | void NEXUS_VideoWindow_GetAnrSettings( |
|---|
| 404 | NEXUS_VideoWindowHandle window, |
|---|
| 405 | NEXUS_VideoWindowAnrSettings *pSettings /* [out] */ |
|---|
| 406 | ); |
|---|
| 407 | |
|---|
| 408 | /** |
|---|
| 409 | Summary: |
|---|
| 410 | Set new ANR settings |
|---|
| 411 | |
|---|
| 412 | Description: |
|---|
| 413 | This function maps to BVDC_Source_SetAnrConfiguration. |
|---|
| 414 | You can find additional documentation in bvdc.h for this function. |
|---|
| 415 | **/ |
|---|
| 416 | NEXUS_Error NEXUS_VideoWindow_SetAnrSettings( |
|---|
| 417 | NEXUS_VideoWindowHandle window, |
|---|
| 418 | const NEXUS_VideoWindowAnrSettings *pSettings |
|---|
| 419 | ); |
|---|
| 420 | |
|---|
| 421 | /** |
|---|
| 422 | Summary: |
|---|
| 423 | Set new ANR settings along with custom data for ANR processing |
|---|
| 424 | |
|---|
| 425 | Description: |
|---|
| 426 | The format of the additional data is private. |
|---|
| 427 | **/ |
|---|
| 428 | NEXUS_Error NEXUS_VideoWindow_SetCustomAnrSettings( |
|---|
| 429 | NEXUS_VideoWindowHandle window, |
|---|
| 430 | const NEXUS_VideoWindowAnrSettings *pSettings, |
|---|
| 431 | const uint8_t *pCustomData, /* attr{null_allowed=y;nelem=numEntries} additional data */ |
|---|
| 432 | unsigned numEntries /* size of pCustomData in bytes */ |
|---|
| 433 | |
|---|
| 434 | ); |
|---|
| 435 | |
|---|
| 436 | /** |
|---|
| 437 | Summary: |
|---|
| 438 | Get current MAD settings |
|---|
| 439 | **/ |
|---|
| 440 | void NEXUS_VideoWindow_GetMadSettings( |
|---|
| 441 | NEXUS_VideoWindowHandle window, |
|---|
| 442 | NEXUS_VideoWindowMadSettings *pSettings /* [out] */ |
|---|
| 443 | ); |
|---|
| 444 | |
|---|
| 445 | /** |
|---|
| 446 | Summary: |
|---|
| 447 | Set new MAD settings |
|---|
| 448 | |
|---|
| 449 | Description: |
|---|
| 450 | This function maps to BVDC_Window_SetDeinterlaceConfiguration. |
|---|
| 451 | You can find additional documentation in bvdc.h for this function. |
|---|
| 452 | **/ |
|---|
| 453 | NEXUS_Error NEXUS_VideoWindow_SetMadSettings( |
|---|
| 454 | NEXUS_VideoWindowHandle window, |
|---|
| 455 | const NEXUS_VideoWindowMadSettings *pSettings |
|---|
| 456 | ); |
|---|
| 457 | |
|---|
| 458 | /** |
|---|
| 459 | Summary: |
|---|
| 460 | Get scaler settings |
|---|
| 461 | **/ |
|---|
| 462 | void NEXUS_VideoWindow_GetScalerSettings( |
|---|
| 463 | NEXUS_VideoWindowHandle window, |
|---|
| 464 | NEXUS_VideoWindowScalerSettings *pSettings /* [out] */ |
|---|
| 465 | ); |
|---|
| 466 | |
|---|
| 467 | /** |
|---|
| 468 | Summary: |
|---|
| 469 | Set new scaler settings |
|---|
| 470 | |
|---|
| 471 | Description: |
|---|
| 472 | This function maps to BVDC_Window_SetScalerConfiguration. |
|---|
| 473 | You can find additional documentation in bvdc.h for this function. |
|---|
| 474 | **/ |
|---|
| 475 | NEXUS_Error NEXUS_VideoWindow_SetScalerSettings( |
|---|
| 476 | NEXUS_VideoWindowHandle window, |
|---|
| 477 | const NEXUS_VideoWindowScalerSettings *pSettings |
|---|
| 478 | ); |
|---|
| 479 | |
|---|
| 480 | /** |
|---|
| 481 | Summary: |
|---|
| 482 | Set the window game mode buffer delay. |
|---|
| 483 | |
|---|
| 484 | Description: |
|---|
| 485 | The game mode delay control can place the sync-slipped window's multi- |
|---|
| 486 | buffer playback pointer to a target offset relative to its capture |
|---|
| 487 | pointer to achieve smaller multi-buffer delay and faster game response. |
|---|
| 488 | |
|---|
| 489 | Note, to make sure the game mode delay control converges and stablize, |
|---|
| 490 | before enabling game mode delay control function, user should make sure |
|---|
| 491 | the followings: |
|---|
| 492 | |
|---|
| 493 | 1) make the window's display track a DPCR timebase; |
|---|
| 494 | 2) program the DPCR timebase to lock the window's source rate; |
|---|
| 495 | |
|---|
| 496 | Also note, |
|---|
| 497 | |
|---|
| 498 | - This function is currently meant for the DTV application with |
|---|
| 499 | DVO panel output; analog output might cause TV rolling or loss of sync |
|---|
| 500 | during adjustment; analog and digital outputs of the same display cannot |
|---|
| 501 | simultaneously turn on if a window enables game mode; |
|---|
| 502 | - A display can only have one window with game mode delay |
|---|
| 503 | control enabled. |
|---|
| 504 | - Only sync-slipped window can have this feature. |
|---|
| 505 | |
|---|
| 506 | This function maps to BVDC_Window_SetGameModeDelay. |
|---|
| 507 | You can find additional documentation in bvdc.h for this function. |
|---|
| 508 | **/ |
|---|
| 509 | NEXUS_Error NEXUS_VideoWindow_SetGameModeDelay( |
|---|
| 510 | NEXUS_VideoWindowHandle window, |
|---|
| 511 | const NEXUS_VideoWindowGameModeDelay *pSettings |
|---|
| 512 | ); |
|---|
| 513 | |
|---|
| 514 | /** |
|---|
| 515 | Summary: |
|---|
| 516 | Get the window game mode buffer delay settings. |
|---|
| 517 | |
|---|
| 518 | Description: |
|---|
| 519 | See Also: |
|---|
| 520 | NEXUS_VideoWindow_SetGameModeDelay |
|---|
| 521 | **/ |
|---|
| 522 | void NEXUS_VideoWindow_GetGameModeDelay( |
|---|
| 523 | NEXUS_VideoWindowHandle window, |
|---|
| 524 | NEXUS_VideoWindowGameModeDelay *pSettings /* [out] */ |
|---|
| 525 | ); |
|---|
| 526 | |
|---|
| 527 | /*************************************************************************** |
|---|
| 528 | Summary: |
|---|
| 529 | Set indices to select filter coefficients from customizable internal tables |
|---|
| 530 | |
|---|
| 531 | Description: |
|---|
| 532 | This structure allows the user to select customized filter coefficients for scaler, hscaler or mad from the built-in |
|---|
| 533 | or user replacable tables in bvdc_coeffs_priv.c. |
|---|
| 534 | Each value in this structure is used as an index into those tables. |
|---|
| 535 | The default for all indices is 0. |
|---|
| 536 | |
|---|
| 537 | Used in NEXUS_VideoWindow_SetCoefficientIndexSettings. |
|---|
| 538 | ***************************************************************************/ |
|---|
| 539 | typedef struct NEXUS_VideoWindowCoefficientIndexSettings |
|---|
| 540 | { |
|---|
| 541 | uint32_t sclVertLuma; /* scaler vertical luma filter index */ |
|---|
| 542 | uint32_t sclHorzLuma; /* scaler horizontal luma filter index */ |
|---|
| 543 | uint32_t sclVertChroma; /* scaler vertical chroma filter index */ |
|---|
| 544 | uint32_t sclHorzChroma; /* scaler horizontal chroma filter index */ |
|---|
| 545 | |
|---|
| 546 | uint32_t hsclHorzLuma; /* hscaler horizontal luma filter index */ |
|---|
| 547 | uint32_t hsclHorzChroma;/* hscaler horizontal chroma filter index */ |
|---|
| 548 | |
|---|
| 549 | uint32_t madHorzLuma; /* MAD horizontal luma filter index */ |
|---|
| 550 | uint32_t madHorzChroma; /* MAD horizontal chroma filter index */ |
|---|
| 551 | } NEXUS_VideoWindowCoefficientIndexSettings; |
|---|
| 552 | |
|---|
| 553 | /** |
|---|
| 554 | Summary: |
|---|
| 555 | Get current coefficient index settings. |
|---|
| 556 | **/ |
|---|
| 557 | void NEXUS_VideoWindow_GetCoefficientIndexSettings( |
|---|
| 558 | NEXUS_VideoWindowHandle window, |
|---|
| 559 | NEXUS_VideoWindowCoefficientIndexSettings *pSettings /* [out] */ |
|---|
| 560 | ); |
|---|
| 561 | |
|---|
| 562 | /** |
|---|
| 563 | Summary: |
|---|
| 564 | Set new coefficient index settings. |
|---|
| 565 | |
|---|
| 566 | Description: |
|---|
| 567 | This function maps to BVDC_Window_SetCoefficientIndex. |
|---|
| 568 | You can find additional documentation in bvdc.h for this function. |
|---|
| 569 | **/ |
|---|
| 570 | NEXUS_Error NEXUS_VideoWindow_SetCoefficientIndexSettings( |
|---|
| 571 | NEXUS_VideoWindowHandle window, |
|---|
| 572 | const NEXUS_VideoWindowCoefficientIndexSettings *pSettings |
|---|
| 573 | ); |
|---|
| 574 | |
|---|
| 575 | #ifdef __cplusplus |
|---|
| 576 | } |
|---|
| 577 | #endif |
|---|
| 578 | |
|---|
| 579 | #endif /* NEXUS_VIDEO_ADJUST_H__ */ |
|---|
| 580 | |
|---|