| 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_display_impl.h $ |
|---|
| 39 | * $brcm_Revision: 12 $ |
|---|
| 40 | * $brcm_Date: 11/15/11 3:27p $ |
|---|
| 41 | * |
|---|
| 42 | * Module Description: |
|---|
| 43 | * |
|---|
| 44 | * Revision History: |
|---|
| 45 | * |
|---|
| 46 | * $brcm_Log: /nexus/modules/display/7400/src/nexus_display_impl.h $ |
|---|
| 47 | * |
|---|
| 48 | * 12 11/15/11 3:27p erickson |
|---|
| 49 | * SW7425-1747: remove old code |
|---|
| 50 | * |
|---|
| 51 | * 11 6/12/09 11:13a erickson |
|---|
| 52 | * PR55952: handle default aspect ratio for 1920x1080 display formats in a |
|---|
| 53 | * consistent way |
|---|
| 54 | * |
|---|
| 55 | * 10 12/1/08 2:24p erickson |
|---|
| 56 | * PR49499: consolidate CUSTOM_VIDEO_ADJ code into |
|---|
| 57 | * NEXUS_VideoAdj_P_SetCustomValues function |
|---|
| 58 | * |
|---|
| 59 | * 9 9/25/08 9:45a erickson |
|---|
| 60 | * PR47113: replace NEXUS_VideoWindow_SetScalerCoefficientIndex with |
|---|
| 61 | * NEXUS_VideoWindow_SetCoefficientIndexSettings |
|---|
| 62 | * |
|---|
| 63 | * 8 9/22/08 9:54a erickson |
|---|
| 64 | * PR46063: support getting format info re: Custom2 inside and outside |
|---|
| 65 | * nexus |
|---|
| 66 | * |
|---|
| 67 | * 7 9/16/08 5:17p erickson |
|---|
| 68 | * PR46967: fix naming of NEXUS_VideoWindowScalerSettings |
|---|
| 69 | * |
|---|
| 70 | * 6 5/23/08 10:49a erickson |
|---|
| 71 | * PR42982: rework PQ Dirty logic to reapply settings on channel change |
|---|
| 72 | * |
|---|
| 73 | * 5 4/3/08 10:17a erickson |
|---|
| 74 | * PR41122: move picture quality code to 7400 |
|---|
| 75 | * |
|---|
| 76 | * 4 4/2/08 2:47p erickson |
|---|
| 77 | * PR40950: move PictureCtrl custom data into function params |
|---|
| 78 | * |
|---|
| 79 | * 3 3/26/08 2:37p erickson |
|---|
| 80 | * PR40950: set custom ANR/DNR data in custom function |
|---|
| 81 | * |
|---|
| 82 | * 2 2/29/08 5:39p erickson |
|---|
| 83 | * PR40156: implement ColorMatrix function |
|---|
| 84 | * |
|---|
| 85 | * 1 1/18/08 2:20p jgarrett |
|---|
| 86 | * PR 38808: Merging to main branch |
|---|
| 87 | * |
|---|
| 88 | * Nexus_Devel/6 1/8/08 3:52p erickson |
|---|
| 89 | * PR36159: rename DNR/ANR/MAD functions to be VideoWindow |
|---|
| 90 | * |
|---|
| 91 | * Nexus_Devel/5 1/8/08 10:57a erickson |
|---|
| 92 | * PR36159: refactor some 3563 Display API's |
|---|
| 93 | * |
|---|
| 94 | * Nexus_Devel/4 11/29/07 1:10p vsilyaev |
|---|
| 95 | * PR 36159: Reworked capture function to return the Nexus Surface |
|---|
| 96 | * |
|---|
| 97 | * Nexus_Devel/3 11/28/07 1:44p vsilyaev |
|---|
| 98 | * PR 36159: Added global UpdateMode, removed per-function ApplyChanges |
|---|
| 99 | * |
|---|
| 100 | * Nexus_Devel/2 11/27/07 10:58a vsilyaev |
|---|
| 101 | * PR36159: Fixed compile time warnings |
|---|
| 102 | * |
|---|
| 103 | * Nexus_Devel/1 11/26/07 3:26p vsilyaev |
|---|
| 104 | * PR36159: PR36159: Bring up Nexus on 93563 platform |
|---|
| 105 | * |
|---|
| 106 | * Nexus_Devel/PR36159/1 11/26/07 10:06a gezhang |
|---|
| 107 | * PR36159: Bring up Nexus on 93563 platform |
|---|
| 108 | * |
|---|
| 109 | * Nexus_Devel/1 10/18/07 9:59p gezhang |
|---|
| 110 | * PR36159: Bring up Nexus on 93563 platform |
|---|
| 111 | * |
|---|
| 112 | **************************************************************************/ |
|---|
| 113 | #ifndef NEXUS_DISPLAY_IMPL_H__ |
|---|
| 114 | #define NEXUS_DISPLAY_IMPL_H__ |
|---|
| 115 | |
|---|
| 116 | #ifdef __cplusplus |
|---|
| 117 | extern "C" { |
|---|
| 118 | #endif |
|---|
| 119 | |
|---|
| 120 | /*=* |
|---|
| 121 | Priv including file for nexus_display.c |
|---|
| 122 | **/ |
|---|
| 123 | |
|---|
| 124 | /* VideoAdj private context */ |
|---|
| 125 | typedef struct NEXUS_VideoAdjContext |
|---|
| 126 | { |
|---|
| 127 | NEXUS_VideoWindowDnrSettings stDnrSettings; |
|---|
| 128 | NEXUS_VideoWindowMadSettings stMadSettings; |
|---|
| 129 | NEXUS_VideoWindowScalerSettings stSclSettings; |
|---|
| 130 | NEXUS_VideoWindowAnrSettings stAnrSettings; |
|---|
| 131 | NEXUS_VideoWindowGameModeDelay stGameModeDelaySettings; |
|---|
| 132 | NEXUS_VideoWindowCoefficientIndexSettings coefficientIndexSettings; |
|---|
| 133 | |
|---|
| 134 | /* Flags to identify settings that were set before a VDC window was created */ |
|---|
| 135 | bool bDnrSet; |
|---|
| 136 | bool bMadSet; |
|---|
| 137 | bool bSclSet; |
|---|
| 138 | bool bAnrSet; |
|---|
| 139 | bool bGameModeDelaySet; |
|---|
| 140 | bool bCoefficientIndexSettingsSet; |
|---|
| 141 | |
|---|
| 142 | /* we copy custom DNR and ANR data into BKNI_Malloc'd memory */ |
|---|
| 143 | void *customDnrData; |
|---|
| 144 | void *customAnrData; |
|---|
| 145 | } NEXUS_VideoAdjContext; |
|---|
| 146 | |
|---|
| 147 | |
|---|
| 148 | /* PictureCtrl private context */ |
|---|
| 149 | typedef struct NEXUS_PictureCtrlContext |
|---|
| 150 | { |
|---|
| 151 | /* color settings */ |
|---|
| 152 | NEXUS_PictureCtrlCommonSettings stCommonSettings; |
|---|
| 153 | /* advanced color settings */ |
|---|
| 154 | NEXUS_PictureCtrlAdvColorSettings stAdvColorSettings; |
|---|
| 155 | /* Customized settings */ |
|---|
| 156 | NEXUS_PictureCtrlSharpnessValue stCustomSharpness; |
|---|
| 157 | NEXUS_PictureCtrlContrastStretch stCustomContrast; |
|---|
| 158 | /* Color management settings */ |
|---|
| 159 | NEXUS_PictureCtrlCmsSettings stCmsSettings; |
|---|
| 160 | /* Dither settings */ |
|---|
| 161 | NEXUS_PictureCtrlDitherSettings stDitherSettings; |
|---|
| 162 | |
|---|
| 163 | /* Flags to identify settings that were set before a VDC window was created */ |
|---|
| 164 | bool bCommonSet; |
|---|
| 165 | bool bAdvColorSet; |
|---|
| 166 | bool bCustomSharpnessSet; |
|---|
| 167 | bool bCustomContrastSet; |
|---|
| 168 | bool bCmsSet; |
|---|
| 169 | bool bDitherSet; |
|---|
| 170 | |
|---|
| 171 | /* we copy custom contrast stretch data into BKNI_Malloc'd memory */ |
|---|
| 172 | void *customContrastStretchData; |
|---|
| 173 | } NEXUS_PictureCtrlContext; |
|---|
| 174 | |
|---|
| 175 | NEXUS_Error NEXUS_PictureCtrl_P_ApplySetSettings( NEXUS_VideoWindowHandle window ); |
|---|
| 176 | NEXUS_Error NEXUS_VideoAdj_P_ApplySetSettings( NEXUS_VideoWindowHandle window ); |
|---|
| 177 | NEXUS_Error NEXUS_P_Display_GetMagnumVideoFormatInfo(NEXUS_DisplayHandle display, NEXUS_VideoFormat videoFormat, BFMT_VideoInfo *pInfo); |
|---|
| 178 | NEXUS_DisplayAspectRatio NEXUS_Display_P_ConvertAspectRatio(NEXUS_DisplayAspectRatio aspectRatio, NEXUS_VideoFormat format); |
|---|
| 179 | |
|---|
| 180 | #ifdef __cplusplus |
|---|
| 181 | } |
|---|
| 182 | #endif |
|---|
| 183 | |
|---|
| 184 | #endif /* NEXUS_DISPLAY_IMPL_H__ */ |
|---|
| 185 | |
|---|