| 1 | /****************************************************************************** |
|---|
| 2 | * (c)2008-2009 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: $ |
|---|
| 39 | * $brcm_Revision: $ |
|---|
| 40 | * $brcm_Date: $ |
|---|
| 41 | * |
|---|
| 42 | * Module Description: |
|---|
| 43 | * |
|---|
| 44 | * The application uses a palette (CLUT - color lookup table) graphics format. |
|---|
| 45 | * |
|---|
| 46 | * Revision History: |
|---|
| 47 | * |
|---|
| 48 | * Created: 09/28/2009 by Jeff Fisher |
|---|
| 49 | * |
|---|
| 50 | * $brcm_Log: $ |
|---|
| 51 | * |
|---|
| 52 | * |
|---|
| 53 | *****************************************************************************/ |
|---|
| 54 | #ifndef BAP_PALETTE_H__ |
|---|
| 55 | #define BAP_PALETTE_H__ |
|---|
| 56 | |
|---|
| 57 | #include "bapp_types.h" |
|---|
| 58 | /* Color enums */ |
|---|
| 59 | typedef enum bcolor_idx_t |
|---|
| 60 | { |
|---|
| 61 | #ifdef CONFIG_GFX_ARGB32 |
|---|
| 62 | /* data from g_yuv_palette */ |
|---|
| 63 | eCOLOR_CLEAR = 0x00000000, |
|---|
| 64 | eCOLOR_BLACK = 0xFF0f0f0f, |
|---|
| 65 | eCOLOR_BLACK_65 = 0xa50f0f0f, |
|---|
| 66 | eCOLOR_WHITE = 0xFFb3b3b3, |
|---|
| 67 | eCOLOR_LT_BLUE = 0xFF000031, |
|---|
| 68 | eCOLOR_MED_BLUE = 0xFF000041, |
|---|
| 69 | eCOLOR_DRK_BLUE = 0xFF00001f, |
|---|
| 70 | eCOLOR_BRT_YELLOW = 0xffbfa600, |
|---|
| 71 | eCOLOR_LT_YELLOW = 0xffc1b203, |
|---|
| 72 | eCOLOR_MED_YELLOW = 0xffdbbe0f, |
|---|
| 73 | eCOLOR_DK_YELLOW = 0xffc4a91e, |
|---|
| 74 | eCOLOR_PALE_YELLOW = 0xfff1eabf, |
|---|
| 75 | eCOLOR_NEON_GREEN = 0xff0ee254, |
|---|
| 76 | #else |
|---|
| 77 | eCOLOR_CLEAR, |
|---|
| 78 | eCOLOR_BLACK, |
|---|
| 79 | eCOLOR_BLACK_65, |
|---|
| 80 | eCOLOR_WHITE, |
|---|
| 81 | eCOLOR_LT_BLUE, |
|---|
| 82 | eCOLOR_MED_BLUE, |
|---|
| 83 | eCOLOR_DRK_BLUE, |
|---|
| 84 | eCOLOR_BRT_YELLOW, |
|---|
| 85 | eCOLOR_LT_YELLOW, |
|---|
| 86 | eCOLOR_MED_YELLOW, |
|---|
| 87 | eCOLOR_DK_YELLOW, |
|---|
| 88 | eCOLOR_PALE_YELLOW, |
|---|
| 89 | eCOLOR_NEON_GREEN |
|---|
| 90 | #endif |
|---|
| 91 | }bcolor_idx_t; |
|---|
| 92 | |
|---|
| 93 | /* palette types */ |
|---|
| 94 | typedef enum bapp_palette_type_t |
|---|
| 95 | { |
|---|
| 96 | ePALETTE_APP, |
|---|
| 97 | ePALETTE_LOGO, |
|---|
| 98 | ePALETTE_EIA_708, |
|---|
| 99 | }bapp_palette_type_t; |
|---|
| 100 | |
|---|
| 101 | |
|---|
| 102 | #ifdef __cplusplus |
|---|
| 103 | extern "C" { |
|---|
| 104 | #endif |
|---|
| 105 | |
|---|
| 106 | bapp_result_t bapp_palette_get(bapp_palette_type_t etype, /* Palette type */ |
|---|
| 107 | unsigned int *p_palette[], /* ARGB palette entries */ |
|---|
| 108 | unsigned int *p_size /* Number of palette entries */ |
|---|
| 109 | ); |
|---|
| 110 | |
|---|
| 111 | #ifdef __cplusplus |
|---|
| 112 | } |
|---|
| 113 | #endif |
|---|
| 114 | |
|---|
| 115 | #endif /* BAP_PALETTE_H__ */ |
|---|
| 116 | |
|---|