Nuvoton
/
NuMaker-mbed-emWin-example
NuMaker emWin HMI
emWin/Include/GUI_Private.h@10:c8165817d92a, 6 months ago (annotated)
- Committer:
- csyang2
- Date:
- Mon Mar 04 15:47:41 2024 +0800
- Revision:
- 10:c8165817d92a
- Parent:
- 1:c0f972361605
Support NuMaker-IoT-M467
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
csyang2 |
1:c0f972361605 | 1 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 2 | * SEGGER Software GmbH * |
csyang2 |
1:c0f972361605 | 3 | * Solutions for real time microcontroller applications * |
csyang2 |
1:c0f972361605 | 4 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 5 | * * |
csyang2 |
1:c0f972361605 | 6 | * (c) 1996 - 2018 SEGGER Microcontroller GmbH * |
csyang2 |
1:c0f972361605 | 7 | * * |
csyang2 |
1:c0f972361605 | 8 | * Internet: www.segger.com Support: support@segger.com * |
csyang2 |
1:c0f972361605 | 9 | * * |
csyang2 |
1:c0f972361605 | 10 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 11 | |
csyang2 |
1:c0f972361605 | 12 | ** emWin V5.48 - Graphical user interface for embedded applications ** |
csyang2 |
1:c0f972361605 | 13 | All Intellectual Property rights in the Software belongs to SEGGER. |
csyang2 |
1:c0f972361605 | 14 | emWin is protected by international copyright laws. Knowledge of the |
csyang2 |
1:c0f972361605 | 15 | source code may not be used to write a similar product. This file may |
csyang2 |
1:c0f972361605 | 16 | only be used in accordance with the following terms: |
csyang2 |
1:c0f972361605 | 17 | |
csyang2 |
1:c0f972361605 | 18 | The software has been licensed by SEGGER Software GmbH to Nuvoton Technology Corporationat the address: No. 4, Creation Rd. III, Hsinchu Science Park, Taiwan |
csyang2 |
1:c0f972361605 | 19 | for the purposes of creating libraries for its |
csyang2 |
1:c0f972361605 | 20 | Arm Cortex-M and Arm9 32-bit microcontrollers, commercialized and distributed by Nuvoton Technology Corporation |
csyang2 |
1:c0f972361605 | 21 | under the terms and conditions of an End User |
csyang2 |
1:c0f972361605 | 22 | License Agreement supplied with the libraries. |
csyang2 |
1:c0f972361605 | 23 | Full source code is available at: www.segger.com |
csyang2 |
1:c0f972361605 | 24 | |
csyang2 |
1:c0f972361605 | 25 | We appreciate your understanding and fairness. |
csyang2 |
1:c0f972361605 | 26 | ---------------------------------------------------------------------- |
csyang2 |
1:c0f972361605 | 27 | Licensing information |
csyang2 |
1:c0f972361605 | 28 | Licensor: SEGGER Software GmbH |
csyang2 |
1:c0f972361605 | 29 | Licensed to: Nuvoton Technology Corporation, No. 4, Creation Rd. III, Hsinchu Science Park, 30077 Hsinchu City, Taiwan |
csyang2 |
1:c0f972361605 | 30 | Licensed SEGGER software: emWin |
csyang2 |
1:c0f972361605 | 31 | License number: GUI-00735 |
csyang2 |
1:c0f972361605 | 32 | License model: emWin License Agreement, signed February 27, 2018 |
csyang2 |
1:c0f972361605 | 33 | Licensed platform: Cortex-M and ARM9 32-bit series microcontroller designed and manufactured by or for Nuvoton Technology Corporation |
csyang2 |
1:c0f972361605 | 34 | ---------------------------------------------------------------------- |
csyang2 |
1:c0f972361605 | 35 | Support and Update Agreement (SUA) |
csyang2 |
1:c0f972361605 | 36 | SUA period: 2018-03-26 - 2019-03-27 |
csyang2 |
1:c0f972361605 | 37 | Contact to extend SUA: sales@segger.com |
csyang2 |
1:c0f972361605 | 38 | ---------------------------------------------------------------------- |
csyang2 |
1:c0f972361605 | 39 | File : GUI_Private.h |
csyang2 |
1:c0f972361605 | 40 | Purpose : GUI internal declarations |
csyang2 |
1:c0f972361605 | 41 | ---------------------------END-OF-HEADER------------------------------ |
csyang2 |
1:c0f972361605 | 42 | */ |
csyang2 |
1:c0f972361605 | 43 | |
csyang2 |
1:c0f972361605 | 44 | #ifndef GUI_PRIVATE_H |
csyang2 |
1:c0f972361605 | 45 | #define GUI_PRIVATE_H |
csyang2 |
1:c0f972361605 | 46 | |
csyang2 |
1:c0f972361605 | 47 | #include "GUI.h" |
csyang2 |
1:c0f972361605 | 48 | #include "LCD_Protected.h" |
csyang2 |
1:c0f972361605 | 49 | #include "GUI_Debug.h" |
csyang2 |
1:c0f972361605 | 50 | #if GUI_WINSUPPORT |
csyang2 |
1:c0f972361605 | 51 | #include "WM_GUI.h" |
csyang2 |
1:c0f972361605 | 52 | #endif |
csyang2 |
1:c0f972361605 | 53 | |
csyang2 |
1:c0f972361605 | 54 | #if defined(__cplusplus) |
csyang2 |
1:c0f972361605 | 55 | extern "C" { /* Make sure we have C-declarations in C++ programs */ |
csyang2 |
1:c0f972361605 | 56 | #endif |
csyang2 |
1:c0f972361605 | 57 | |
csyang2 |
1:c0f972361605 | 58 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 59 | * |
csyang2 |
1:c0f972361605 | 60 | * Defaults for config switches |
csyang2 |
1:c0f972361605 | 61 | * |
csyang2 |
1:c0f972361605 | 62 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 63 | |
csyang2 |
1:c0f972361605 | 64 | The config switches below do not affect the interface in GUI.h and |
csyang2 |
1:c0f972361605 | 65 | are therefor not required to be in GUI.h. |
csyang2 |
1:c0f972361605 | 66 | */ |
csyang2 |
1:c0f972361605 | 67 | |
csyang2 |
1:c0f972361605 | 68 | /* Short address area. |
csyang2 |
1:c0f972361605 | 69 | For most compilers, this is "near" or "__near" |
csyang2 |
1:c0f972361605 | 70 | We do not use this except for some CPUs which we know to always have some |
csyang2 |
1:c0f972361605 | 71 | near memory, because the GUI_Context and some other data will be declared |
csyang2 |
1:c0f972361605 | 72 | to be in this short address (near) memory area as it has a major effect |
csyang2 |
1:c0f972361605 | 73 | on performance. |
csyang2 |
1:c0f972361605 | 74 | Please define in GUIConf.h (if you want to use it) |
csyang2 |
1:c0f972361605 | 75 | */ |
csyang2 |
1:c0f972361605 | 76 | #ifndef GUI_SADDR |
csyang2 |
1:c0f972361605 | 77 | #define GUI_SADDR |
csyang2 |
1:c0f972361605 | 78 | #endif |
csyang2 |
1:c0f972361605 | 79 | |
csyang2 |
1:c0f972361605 | 80 | #ifndef GUI_DEFAULT_FONT |
csyang2 |
1:c0f972361605 | 81 | #define GUI_DEFAULT_FONT &GUI_Font6x8 |
csyang2 |
1:c0f972361605 | 82 | #endif |
csyang2 |
1:c0f972361605 | 83 | |
csyang2 |
1:c0f972361605 | 84 | #ifndef GUI_DEFAULT_CURSOR |
csyang2 |
1:c0f972361605 | 85 | #define GUI_DEFAULT_CURSOR &GUI_CursorArrowM |
csyang2 |
1:c0f972361605 | 86 | #endif |
csyang2 |
1:c0f972361605 | 87 | |
csyang2 |
1:c0f972361605 | 88 | #ifndef GUI_DEFAULT_BKCOLOR |
csyang2 |
1:c0f972361605 | 89 | #define GUI_DEFAULT_BKCOLOR GUI_BLACK |
csyang2 |
1:c0f972361605 | 90 | #endif |
csyang2 |
1:c0f972361605 | 91 | |
csyang2 |
1:c0f972361605 | 92 | #ifndef GUI_DEFAULT_COLOR |
csyang2 |
1:c0f972361605 | 93 | #define GUI_DEFAULT_COLOR GUI_WHITE |
csyang2 |
1:c0f972361605 | 94 | #endif |
csyang2 |
1:c0f972361605 | 95 | |
csyang2 |
1:c0f972361605 | 96 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 97 | * |
csyang2 |
1:c0f972361605 | 98 | * Angles |
csyang2 |
1:c0f972361605 | 99 | * |
csyang2 |
1:c0f972361605 | 100 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 101 | */ |
csyang2 |
1:c0f972361605 | 102 | #define GUI_45DEG 512 |
csyang2 |
1:c0f972361605 | 103 | #define GUI_90DEG (2 * GUI_45DEG) |
csyang2 |
1:c0f972361605 | 104 | #define GUI_180DEG (4 * GUI_45DEG) |
csyang2 |
1:c0f972361605 | 105 | #define GUI_360DEG (8 * GUI_45DEG) |
csyang2 |
1:c0f972361605 | 106 | |
csyang2 |
1:c0f972361605 | 107 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 108 | * |
csyang2 |
1:c0f972361605 | 109 | * Locking checks |
csyang2 |
1:c0f972361605 | 110 | * |
csyang2 |
1:c0f972361605 | 111 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 112 | */ |
csyang2 |
1:c0f972361605 | 113 | #if defined (WIN32) && defined (_DEBUG) && GUI_OS |
csyang2 |
1:c0f972361605 | 114 | #define GUI_ASSERT_LOCK() GUITASK_AssertLock() |
csyang2 |
1:c0f972361605 | 115 | #define GUI_ASSERT_NO_LOCK() GUITASK_AssertNoLock() |
csyang2 |
1:c0f972361605 | 116 | void GUITASK_AssertLock(void); |
csyang2 |
1:c0f972361605 | 117 | void GUITASK_AssertNoLock(void); |
csyang2 |
1:c0f972361605 | 118 | #else |
csyang2 |
1:c0f972361605 | 119 | #define GUI_ASSERT_LOCK() |
csyang2 |
1:c0f972361605 | 120 | #define GUI_ASSERT_NO_LOCK() |
csyang2 |
1:c0f972361605 | 121 | #endif |
csyang2 |
1:c0f972361605 | 122 | |
csyang2 |
1:c0f972361605 | 123 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 124 | * |
csyang2 |
1:c0f972361605 | 125 | * Division tables |
csyang2 |
1:c0f972361605 | 126 | * |
csyang2 |
1:c0f972361605 | 127 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 128 | */ |
csyang2 |
1:c0f972361605 | 129 | extern const U8 GUI__aConvert_15_255[(1 << 4)]; |
csyang2 |
1:c0f972361605 | 130 | extern const U8 GUI__aConvert_31_255[(1 << 5)]; |
csyang2 |
1:c0f972361605 | 131 | extern const U8 GUI__aConvert_63_255[(1 << 6)]; |
csyang2 |
1:c0f972361605 | 132 | extern const U8 GUI__aConvert_255_15[(1 << 8)]; |
csyang2 |
1:c0f972361605 | 133 | extern const U8 GUI__aConvert_255_31[(1 << 8)]; |
csyang2 |
1:c0f972361605 | 134 | extern const U8 GUI__aConvert_255_63[(1 << 8)]; |
csyang2 |
1:c0f972361605 | 135 | |
csyang2 |
1:c0f972361605 | 136 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 137 | * |
csyang2 |
1:c0f972361605 | 138 | * Usage internals |
csyang2 |
1:c0f972361605 | 139 | * |
csyang2 |
1:c0f972361605 | 140 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 141 | */ |
csyang2 |
1:c0f972361605 | 142 | typedef GUI_HMEM GUI_USAGE_Handle; |
csyang2 |
1:c0f972361605 | 143 | typedef struct tsUSAGE_APIList tUSAGE_APIList; |
csyang2 |
1:c0f972361605 | 144 | typedef struct GUI_Usage GUI_USAGE; |
csyang2 |
1:c0f972361605 | 145 | #define GUI_USAGE_h GUI_USAGE_Handle |
csyang2 |
1:c0f972361605 | 146 | |
csyang2 |
1:c0f972361605 | 147 | typedef GUI_USAGE_h tUSAGE_CreateCompatible(GUI_USAGE * p); |
csyang2 |
1:c0f972361605 | 148 | typedef void tUSAGE_AddPixel (GUI_USAGE * p, int x, int y); |
csyang2 |
1:c0f972361605 | 149 | typedef void tUSAGE_AddHLine (GUI_USAGE * p, int x0, int y0, int len); |
csyang2 |
1:c0f972361605 | 150 | typedef void tUSAGE_Clear (GUI_USAGE * p); |
csyang2 |
1:c0f972361605 | 151 | typedef void tUSAGE_Delete (GUI_USAGE_h h); |
csyang2 |
1:c0f972361605 | 152 | typedef int tUSAGE_GetNextDirty (GUI_USAGE * p, int * pxOff, int yOff); |
csyang2 |
1:c0f972361605 | 153 | #define GUI_USAGE_LOCK_H(h) ((GUI_USAGE *)GUI_LOCK_H(h)) |
csyang2 |
1:c0f972361605 | 154 | |
csyang2 |
1:c0f972361605 | 155 | void GUI_USAGE_DecUseCnt(GUI_USAGE_Handle hUsage); |
csyang2 |
1:c0f972361605 | 156 | |
csyang2 |
1:c0f972361605 | 157 | GUI_USAGE_Handle GUI_USAGE_BM_Create(int x0, int y0, int xsize, int ysize, int Flags); |
csyang2 |
1:c0f972361605 | 158 | void GUI_USAGE_Select(GUI_USAGE_Handle hUsage); |
csyang2 |
1:c0f972361605 | 159 | void GUI_USAGE_AddRect(GUI_USAGE * pUsage, int x0, int y0, int xSize, int ySize); |
csyang2 |
1:c0f972361605 | 160 | #define GUI_USAGE_AddPixel(p, x,y) p->pAPI->pfAddPixel(p,x,y) |
csyang2 |
1:c0f972361605 | 161 | #define GUI_USAGE_AddHLine(p,x,y,len) p->pAPI->pfAddHLine(p,x,y,len) |
csyang2 |
1:c0f972361605 | 162 | #define GUI_USAGE_Clear(p) p->pAPI->pfClear(p) |
csyang2 |
1:c0f972361605 | 163 | #define GUI_USAGE_Delete(p) p->pAPI->pfDelete(p) |
csyang2 |
1:c0f972361605 | 164 | #define GUI_USAGE_GetNextDirty(p,pxOff, yOff) p->pAPI->pfGetNextDirty(p,pxOff, yOff) |
csyang2 |
1:c0f972361605 | 165 | |
csyang2 |
1:c0f972361605 | 166 | struct tsUSAGE_APIList { |
csyang2 |
1:c0f972361605 | 167 | tUSAGE_AddPixel * pfAddPixel; |
csyang2 |
1:c0f972361605 | 168 | tUSAGE_AddHLine * pfAddHLine; |
csyang2 |
1:c0f972361605 | 169 | tUSAGE_Clear * pfClear; |
csyang2 |
1:c0f972361605 | 170 | tUSAGE_CreateCompatible * pfCreateCompatible; |
csyang2 |
1:c0f972361605 | 171 | tUSAGE_Delete * pfDelete; |
csyang2 |
1:c0f972361605 | 172 | tUSAGE_GetNextDirty * pfGetNextDirty; |
csyang2 |
1:c0f972361605 | 173 | } ; |
csyang2 |
1:c0f972361605 | 174 | |
csyang2 |
1:c0f972361605 | 175 | struct GUI_Usage { |
csyang2 |
1:c0f972361605 | 176 | I16P x0, y0, XSize, YSize; |
csyang2 |
1:c0f972361605 | 177 | const tUSAGE_APIList * pAPI; |
csyang2 |
1:c0f972361605 | 178 | I16 UseCnt; |
csyang2 |
1:c0f972361605 | 179 | }; |
csyang2 |
1:c0f972361605 | 180 | |
csyang2 |
1:c0f972361605 | 181 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 182 | * |
csyang2 |
1:c0f972361605 | 183 | * GUI_MEMDEV |
csyang2 |
1:c0f972361605 | 184 | * |
csyang2 |
1:c0f972361605 | 185 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 186 | */ |
csyang2 |
1:c0f972361605 | 187 | #if GUI_SUPPORT_MEMDEV |
csyang2 |
1:c0f972361605 | 188 | |
csyang2 |
1:c0f972361605 | 189 | typedef struct { |
csyang2 |
1:c0f972361605 | 190 | GUI_DEVICE * pDevice; |
csyang2 |
1:c0f972361605 | 191 | I16P x0, y0, XSize, YSize; |
csyang2 |
1:c0f972361605 | 192 | unsigned BytesPerLine; |
csyang2 |
1:c0f972361605 | 193 | unsigned BitsPerPixel; |
csyang2 |
1:c0f972361605 | 194 | GUI_HMEM hUsage; |
csyang2 |
1:c0f972361605 | 195 | } GUI_MEMDEV; |
csyang2 |
1:c0f972361605 | 196 | |
csyang2 |
1:c0f972361605 | 197 | #define GUI_MEMDEV_LOCK_H(h) ((GUI_MEMDEV *)GUI_LOCK_H(h)) |
csyang2 |
1:c0f972361605 | 198 | |
csyang2 |
1:c0f972361605 | 199 | void GUI_MEMDEV__CopyFromLCD (GUI_MEMDEV_Handle hMem); |
csyang2 |
1:c0f972361605 | 200 | void GUI_MEMDEV__GetRect (GUI_RECT * pRect); |
csyang2 |
1:c0f972361605 | 201 | unsigned GUI_MEMDEV__Color2Index (LCD_COLOR Color); |
csyang2 |
1:c0f972361605 | 202 | LCD_COLOR GUI_MEMDEV__Index2Color (int Index); |
csyang2 |
1:c0f972361605 | 203 | unsigned int GUI_MEMDEV__GetIndexMask(void); |
csyang2 |
1:c0f972361605 | 204 | void GUI_MEMDEV__SetAlphaCallback(unsigned(* pcbSetAlpha)(U8)); |
csyang2 |
1:c0f972361605 | 205 | |
csyang2 |
1:c0f972361605 | 206 | GUI_MEMDEV_Handle GUI_MEMDEV__CreateFixed(int x0, int y0, int xSize, int ySize, int Flags, |
csyang2 |
1:c0f972361605 | 207 | const GUI_DEVICE_API * pDeviceAPI, |
csyang2 |
1:c0f972361605 | 208 | const LCD_API_COLOR_CONV * pColorConvAPI); |
csyang2 |
1:c0f972361605 | 209 | |
csyang2 |
1:c0f972361605 | 210 | void GUI_MEMDEV__DrawSizedAt (GUI_MEMDEV_Handle hMem, int xPos, int yPos, int xSize, int ySize); |
csyang2 |
1:c0f972361605 | 211 | GUI_MEMDEV_Handle GUI_MEMDEV__GetEmptyCopy32 (GUI_MEMDEV_Handle hMem, int * pxSize, int * pySize, int * pxPos, int * pyPos); |
csyang2 |
1:c0f972361605 | 212 | void GUI_MEMDEV__ReadLine (int x0, int y, int x1, LCD_PIXELINDEX * pBuffer); |
csyang2 |
1:c0f972361605 | 213 | void GUI_MEMDEV__WriteToActiveAlpha (GUI_MEMDEV_Handle hMem,int x, int y); |
csyang2 |
1:c0f972361605 | 214 | void GUI_MEMDEV__WriteToActiveAt (GUI_MEMDEV_Handle hMem,int x, int y); |
csyang2 |
1:c0f972361605 | 215 | void GUI_MEMDEV__WriteToActiveOpaque(GUI_MEMDEV_Handle hMem,int x, int y); |
csyang2 |
1:c0f972361605 | 216 | void * GUI_MEMDEV__XY2PTR (int x,int y); |
csyang2 |
1:c0f972361605 | 217 | void * GUI_MEMDEV__XY2PTREx (GUI_MEMDEV * pDev, int x,int y); |
csyang2 |
1:c0f972361605 | 218 | void GUI_MEMDEV__BlendColor32 (GUI_MEMDEV_Handle hMem, U32 BlendColor, U8 BlendIntens); |
csyang2 |
1:c0f972361605 | 219 | |
csyang2 |
1:c0f972361605 | 220 | unsigned GUI__AlphaPreserveTrans(int OnOff); |
csyang2 |
1:c0f972361605 | 221 | |
csyang2 |
1:c0f972361605 | 222 | extern unsigned GUI_MEMDEV__TimePerFrame; |
csyang2 |
1:c0f972361605 | 223 | |
csyang2 |
1:c0f972361605 | 224 | #define GUI_TIME_PER_FRAME (GUI_TIMER_TIME)GUI_MEMDEV__TimePerFrame |
csyang2 |
1:c0f972361605 | 225 | |
csyang2 |
1:c0f972361605 | 226 | #define GUI_POS_AUTO -4095 /* Position value for auto-pos */ |
csyang2 |
1:c0f972361605 | 227 | |
csyang2 |
1:c0f972361605 | 228 | #endif |
csyang2 |
1:c0f972361605 | 229 | |
csyang2 |
1:c0f972361605 | 230 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 231 | * |
csyang2 |
1:c0f972361605 | 232 | * LCD_HL_ level defines |
csyang2 |
1:c0f972361605 | 233 | * |
csyang2 |
1:c0f972361605 | 234 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 235 | */ |
csyang2 |
1:c0f972361605 | 236 | #define LCD_HL_DrawHLine GUI_pContext->pLCD_HL->pfDrawHLine |
csyang2 |
1:c0f972361605 | 237 | #define LCD_HL_DrawPixel GUI_pContext->pLCD_HL->pfDrawPixel |
csyang2 |
1:c0f972361605 | 238 | |
csyang2 |
1:c0f972361605 | 239 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 240 | * |
csyang2 |
1:c0f972361605 | 241 | * Helper functions |
csyang2 |
1:c0f972361605 | 242 | * |
csyang2 |
1:c0f972361605 | 243 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 244 | */ |
csyang2 |
1:c0f972361605 | 245 | #define GUI_ZEROINIT(Obj) GUI__MEMSET(Obj, 0, sizeof(Obj)) |
csyang2 |
1:c0f972361605 | 246 | int GUI_cos(int angle); |
csyang2 |
1:c0f972361605 | 247 | int GUI_sin(int angle); |
csyang2 |
1:c0f972361605 | 248 | extern const U32 GUI_Pow10[10]; |
csyang2 |
1:c0f972361605 | 249 | |
csyang2 |
1:c0f972361605 | 250 | /* Multi-touch */ |
csyang2 |
1:c0f972361605 | 251 | void GUI_MTOUCH__ManagePID(int OnOff); |
csyang2 |
1:c0f972361605 | 252 | |
csyang2 |
1:c0f972361605 | 253 | /* Anti-aliased drawing */ |
csyang2 |
1:c0f972361605 | 254 | int GUI_AA_Init (int x0, int x1); |
csyang2 |
1:c0f972361605 | 255 | int GUI_AA_Init_HiRes (int x0, int x1); |
csyang2 |
1:c0f972361605 | 256 | void GUI_AA_Exit (void); |
csyang2 |
1:c0f972361605 | 257 | I16 GUI_AA_HiRes2Pixel(int HiRes); |
csyang2 |
1:c0f972361605 | 258 | |
csyang2 |
1:c0f972361605 | 259 | void GL_DrawCircleAA_HiRes(int x0, int y0, int r); |
csyang2 |
1:c0f972361605 | 260 | void GL_FillCircleAA_HiRes (int x0, int y0, int r); |
csyang2 |
1:c0f972361605 | 261 | void GL_FillEllipseAA_HiRes(int x0, int y0, int rx, int ry); |
csyang2 |
1:c0f972361605 | 262 | |
csyang2 |
1:c0f972361605 | 263 | void GUI_AA__DrawCharAA2(int x0, int y0, int XSize, int YSize, int BytesPerLine, const U8 * pData); |
csyang2 |
1:c0f972361605 | 264 | void GUI_AA__DrawCharAA4(int x0, int y0, int XSize, int YSize, int BytesPerLine, const U8 * pData); |
csyang2 |
1:c0f972361605 | 265 | void GUI_AA__DrawCharAA8(int x0, int y0, int XSize, int YSize, int BytesPerLine, const U8 * pData); |
csyang2 |
1:c0f972361605 | 266 | |
csyang2 |
1:c0f972361605 | 267 | /* Alpha blending helper functions */ |
csyang2 |
1:c0f972361605 | 268 | #define GUI_ALPHABLENDING_DONE (1 << 0) |
csyang2 |
1:c0f972361605 | 269 | |
csyang2 |
1:c0f972361605 | 270 | int GUI__GetAlphaBuffer (U32 ** ppCurrent, U32 ** ppConvert, U32 ** ppData, int * pVXSizeMax); |
csyang2 |
1:c0f972361605 | 271 | int GUI__AllocAlphaBuffer (int AllocDataBuffer); |
csyang2 |
1:c0f972361605 | 272 | U32 * GUI__DoAlphaBlending (int x, int y, U32 * pData, int xSize, tLCDDEV_Index2Color * pfIndex2Color_DEV, int * pDone); |
csyang2 |
1:c0f972361605 | 273 | unsigned GUI__SetAlphaBufferSize(int xSize); |
csyang2 |
1:c0f972361605 | 274 | |
csyang2 |
1:c0f972361605 | 275 | /* System independent font routines */ |
csyang2 |
1:c0f972361605 | 276 | int GUI_SIF__GetCharDistX (U16P c, int * pSizeX); |
csyang2 |
1:c0f972361605 | 277 | void GUI_SIF__GetFontInfo (const GUI_FONT * pFont, GUI_FONTINFO * pfi); |
csyang2 |
1:c0f972361605 | 278 | char GUI_SIF__IsInFont (const GUI_FONT * pFont, U16 c); |
csyang2 |
1:c0f972361605 | 279 | const U8 * GUI_SIF__GetpCharInfo (const GUI_FONT * pFont, U16P c, unsigned SizeOfCharInfo); |
csyang2 |
1:c0f972361605 | 280 | int GUI_SIF__GetNumCharAreas (const GUI_FONT * pFont); |
csyang2 |
1:c0f972361605 | 281 | int GUI_SIF__GetCharDistX_ExtFrm(U16P c, int * pSizeX); |
csyang2 |
1:c0f972361605 | 282 | void GUI_SIF__GetFontInfo_ExtFrm (const GUI_FONT * pFont, GUI_FONTINFO * pfi); |
csyang2 |
1:c0f972361605 | 283 | char GUI_SIF__IsInFont_ExtFrm (const GUI_FONT * pFont, U16 c); |
csyang2 |
1:c0f972361605 | 284 | int GUI_SIF__GetCharInfo_ExtFrm (U16P c, GUI_CHARINFO_EXT * pInfo); |
csyang2 |
1:c0f972361605 | 285 | void GUI_SIF__ClearLine_ExtFrm (const char * s, int Len); |
csyang2 |
1:c0f972361605 | 286 | |
csyang2 |
1:c0f972361605 | 287 | /* External binary font routines */ |
csyang2 |
1:c0f972361605 | 288 | int GUI_XBF__GetOff (const GUI_XBF_DATA * pXBF_Data, unsigned c, U32 * pOff); |
csyang2 |
1:c0f972361605 | 289 | int GUI_XBF__GetOffAndSize(const GUI_XBF_DATA * pXBF_Data, unsigned c, U32 * pOff, U16 * pSize); |
csyang2 |
1:c0f972361605 | 290 | int GUI_XBF__GetCharDistX (U16P c, int * pSizeX); |
csyang2 |
1:c0f972361605 | 291 | void GUI_XBF__GetFontInfo (const GUI_FONT * pFont, GUI_FONTINFO * pInfo); |
csyang2 |
1:c0f972361605 | 292 | char GUI_XBF__IsInFont (const GUI_FONT * pFont, U16 c); |
csyang2 |
1:c0f972361605 | 293 | int GUI_XBF__GetCharInfo (U16P c, GUI_CHARINFO_EXT * pInfo); |
csyang2 |
1:c0f972361605 | 294 | void GUI_XBF__ClearLine (const char * s, int Len); |
csyang2 |
1:c0f972361605 | 295 | |
csyang2 |
1:c0f972361605 | 296 | /* Conversion routines */ |
csyang2 |
1:c0f972361605 | 297 | void GUI_AddHex (U32 v, U8 Len, char ** ps); |
csyang2 |
1:c0f972361605 | 298 | void GUI_AddBin (U32 v, U8 Len, char ** ps); |
csyang2 |
1:c0f972361605 | 299 | void GUI_AddDecMin (I32 v, char ** ps); |
csyang2 |
1:c0f972361605 | 300 | void GUI_AddDecShift(I32 v, U8 Len, U8 Shift, char ** ps); |
csyang2 |
1:c0f972361605 | 301 | long GUI_AddSign (long v, char ** ps); |
csyang2 |
1:c0f972361605 | 302 | int GUI_Long2Len (I32 v); |
csyang2 |
1:c0f972361605 | 303 | |
csyang2 |
1:c0f972361605 | 304 | #define GUI_UC__GetCharSize(sText) GUI_pUC_API->pfGetCharSize(sText) |
csyang2 |
1:c0f972361605 | 305 | #define GUI_UC__GetCharCode(sText) GUI_pUC_API->pfGetCharCode(sText) |
csyang2 |
1:c0f972361605 | 306 | |
csyang2 |
1:c0f972361605 | 307 | int GUI_UC__CalcSizeOfChar (U16 Char); |
csyang2 |
1:c0f972361605 | 308 | U16 GUI_UC__GetCharCodeInc (const char ** ps); |
csyang2 |
1:c0f972361605 | 309 | int GUI_UC__NumChars2NumBytes(const char * s, int NumChars); |
csyang2 |
1:c0f972361605 | 310 | int GUI_UC__NumBytes2NumChars(const char * s, int NumBytes); |
csyang2 |
1:c0f972361605 | 311 | |
csyang2 |
1:c0f972361605 | 312 | int GUI__GetLineNumChars (const char * s, int MaxNumChars); |
csyang2 |
1:c0f972361605 | 313 | int GUI__GetNumChars (const char * s); |
csyang2 |
1:c0f972361605 | 314 | int GUI__GetOverlap (U16 Char); |
csyang2 |
1:c0f972361605 | 315 | int GUI__GetLineDistX (const char * s, int Len); |
csyang2 |
1:c0f972361605 | 316 | int GUI__GetFontSizeY (void); |
csyang2 |
1:c0f972361605 | 317 | int GUI__HandleEOLine (const char ** ps); |
csyang2 |
1:c0f972361605 | 318 | void GUI__InvertRectColors (int x0, int y0, int x1, int y1); |
csyang2 |
1:c0f972361605 | 319 | void GUI__DispLine (const char * s, int Len, const GUI_RECT * pr); |
csyang2 |
1:c0f972361605 | 320 | void GUI__AddSpaceHex (U32 v, U8 Len, char ** ps); |
csyang2 |
1:c0f972361605 | 321 | void GUI__CalcTextRect (const char * pText, const GUI_RECT * pTextRectIn, GUI_RECT * pTextRectOut, int TextAlign); |
csyang2 |
1:c0f972361605 | 322 | |
csyang2 |
1:c0f972361605 | 323 | void GUI__ClearTextBackground(int xDist, int yDist); |
csyang2 |
1:c0f972361605 | 324 | |
csyang2 |
1:c0f972361605 | 325 | int GUI__WrapGetNumCharsDisp (const char * pText, int xSize, GUI_WRAPMODE WrapMode); |
csyang2 |
1:c0f972361605 | 326 | int GUI__WrapGetNumCharsToNextLine (const char * pText, int xSize, GUI_WRAPMODE WrapMode); |
csyang2 |
1:c0f972361605 | 327 | int GUI__WrapGetNumBytesToNextLine (const char * pText, int xSize, GUI_WRAPMODE WrapMode); |
csyang2 |
1:c0f972361605 | 328 | //void GUI__memset (U8 * p, U8 Fill, int NumBytes); |
csyang2 |
1:c0f972361605 | 329 | void GUI__memset16 (U16 * p, U16 Fill, int NumWords); |
csyang2 |
1:c0f972361605 | 330 | int GUI__strlen (const char * s); |
csyang2 |
1:c0f972361605 | 331 | int GUI__strcmp (const char * s0, const char * s1); |
csyang2 |
1:c0f972361605 | 332 | int GUI__strcmp_hp (GUI_HMEM hs0, const char * s1); |
csyang2 |
1:c0f972361605 | 333 | |
csyang2 |
1:c0f972361605 | 334 | /* Get cursor position */ |
csyang2 |
1:c0f972361605 | 335 | int GUI__GetCursorPosX (const char * s, int Index, int MaxNumChars); |
csyang2 |
1:c0f972361605 | 336 | int GUI__GetCursorPosChar (const char * s, int x, int NumCharsToNextLine); |
csyang2 |
1:c0f972361605 | 337 | U16 GUI__GetCursorCharacter(const char * s, int Index, int MaxNumChars, int * pIsRTL); |
csyang2 |
1:c0f972361605 | 338 | |
csyang2 |
1:c0f972361605 | 339 | /* Arabic support (tbd) */ |
csyang2 |
1:c0f972361605 | 340 | U16 GUI__GetPresentationForm (U16 Char, U16 Next, U16 Prev, int * pIgnoreNext, const char * s); |
csyang2 |
1:c0f972361605 | 341 | int GUI__IsArabicCharacter (U16 c); |
csyang2 |
1:c0f972361605 | 342 | |
csyang2 |
1:c0f972361605 | 343 | /* BiDi support */ |
csyang2 |
1:c0f972361605 | 344 | int GUI__BIDI_Log2Vis (const char * s, int NumChars, char * pBuffer, int BufferSize); |
csyang2 |
1:c0f972361605 | 345 | int GUI__BIDI_GetCursorPosX (const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 346 | int GUI__BIDI_GetCursorPosChar (const char * s, int NumChars, int x); |
csyang2 |
1:c0f972361605 | 347 | U16 GUI__BIDI_GetLogChar (const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 348 | int GUI__BIDI_GetCharDir (const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 349 | int GUI__BIDI_IsNSM (U16 Char); |
csyang2 |
1:c0f972361605 | 350 | U16 GUI__BIDI_GetCursorCharacter(const char * s, int Index, int MaxNumChars, int * pIsRTL); |
csyang2 |
1:c0f972361605 | 351 | int GUI__BIDI_GetWordWrap (const char * s, int xSize, int * pxDist); |
csyang2 |
1:c0f972361605 | 352 | int GUI__BIDI_GetCharWrap (const char * s, int xSize); |
csyang2 |
1:c0f972361605 | 353 | |
csyang2 |
1:c0f972361605 | 354 | #if (GUI_USE_BIDI2) |
csyang2 |
1:c0f972361605 | 355 | |
csyang2 |
1:c0f972361605 | 356 | #define GUI__BIDI_Log2Vis GUI__BIDI2_Log2Vis |
csyang2 |
1:c0f972361605 | 357 | #define GUI__BIDI_GetCursorPosX GUI__BIDI2_GetCursorPosX |
csyang2 |
1:c0f972361605 | 358 | #define GUI__BIDI_GetCursorPosChar GUI__BIDI2_GetCursorPosChar |
csyang2 |
1:c0f972361605 | 359 | #define GUI__BIDI_GetLogChar GUI__BIDI2_GetLogChar |
csyang2 |
1:c0f972361605 | 360 | #define GUI__BIDI_GetCharDir GUI__BIDI2_GetCharDir |
csyang2 |
1:c0f972361605 | 361 | #define GUI__BIDI_IsNSM GUI__BIDI2_IsNSM |
csyang2 |
1:c0f972361605 | 362 | #define GUI__BIDI_GetCursorCharacter GUI__BIDI2_GetCursorCharacter |
csyang2 |
1:c0f972361605 | 363 | #define GUI__BIDI_GetWordWrap GUI__BIDI2_GetWordWrap |
csyang2 |
1:c0f972361605 | 364 | #define GUI__BIDI_GetCharWrap GUI__BIDI2_GetCharWrap |
csyang2 |
1:c0f972361605 | 365 | #define GUI__BIDI_SetBaseDir GUI__BIDI2_SetBaseDir |
csyang2 |
1:c0f972361605 | 366 | #define GUI__BIDI_GetBaseDir GUI__BIDI2_GetBaseDir |
csyang2 |
1:c0f972361605 | 367 | |
csyang2 |
1:c0f972361605 | 368 | int GUI__BIDI_Log2Vis (const char * s, int NumChars, char * pBuffer, int BufferSize); |
csyang2 |
1:c0f972361605 | 369 | int GUI__BIDI_GetCursorPosX (const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 370 | int GUI__BIDI_GetCursorPosChar (const char * s, int NumChars, int x); |
csyang2 |
1:c0f972361605 | 371 | U16 GUI__BIDI_GetLogChar (const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 372 | int GUI__BIDI_GetCharDir (const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 373 | int GUI__BIDI_IsNSM (U16 Char); |
csyang2 |
1:c0f972361605 | 374 | U16 GUI__BIDI_GetCursorCharacter(const char * s, int Index, int MaxNumChars, int * pIsRTL); |
csyang2 |
1:c0f972361605 | 375 | int GUI__BIDI_GetWordWrap (const char * s, int xSize, int * pxDist); |
csyang2 |
1:c0f972361605 | 376 | int GUI__BIDI_GetCharWrap (const char * s, int xSize); |
csyang2 |
1:c0f972361605 | 377 | void GUI__BIDI_SetBaseDir (int Dir); |
csyang2 |
1:c0f972361605 | 378 | int GUI__BIDI_GetBaseDir (void); |
csyang2 |
1:c0f972361605 | 379 | |
csyang2 |
1:c0f972361605 | 380 | #else |
csyang2 |
1:c0f972361605 | 381 | |
csyang2 |
1:c0f972361605 | 382 | #define GUI__BIDI_SetBaseDir |
csyang2 |
1:c0f972361605 | 383 | #define GUI__BIDI_GetBaseDir |
csyang2 |
1:c0f972361605 | 384 | |
csyang2 |
1:c0f972361605 | 385 | #endif |
csyang2 |
1:c0f972361605 | 386 | |
csyang2 |
1:c0f972361605 | 387 | const char * GUI__BIDI_Log2VisBuffered(const char * s, int * pMaxNumChars, int Mode); |
csyang2 |
1:c0f972361605 | 388 | |
csyang2 |
1:c0f972361605 | 389 | extern int GUI__BIDI_Enabled; |
csyang2 |
1:c0f972361605 | 390 | |
csyang2 |
1:c0f972361605 | 391 | extern int (* _pfGUI__BIDI_Log2Vis )(const char * s, int NumChars, char * pBuffer, int BufferSize); |
csyang2 |
1:c0f972361605 | 392 | extern int (* _pfGUI__BIDI_GetCursorPosX )(const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 393 | extern int (* _pfGUI__BIDI_GetCursorPosChar)(const char * s, int NumChars, int x); |
csyang2 |
1:c0f972361605 | 394 | extern U16 (* _pfGUI__BIDI_GetLogChar )(const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 395 | extern int (* _pfGUI__BIDI_GetCharDir )(const char * s, int NumChars, int Index); |
csyang2 |
1:c0f972361605 | 396 | extern int (* _pfGUI__BIDI_IsNSM )(U16 Char); |
csyang2 |
1:c0f972361605 | 397 | |
csyang2 |
1:c0f972361605 | 398 | /* BiDi-related function pointers */ |
csyang2 |
1:c0f972361605 | 399 | extern const char * (* GUI_CharLine_pfLog2Vis)(const char * s, int * pMaxNumChars, int Mode); |
csyang2 |
1:c0f972361605 | 400 | |
csyang2 |
1:c0f972361605 | 401 | extern int (* GUI__GetCursorPos_pfGetPosX) (const char * s, int MaxNumChars, int Index); |
csyang2 |
1:c0f972361605 | 402 | extern int (* GUI__GetCursorPos_pfGetPosChar) (const char * s, int MaxNumChars, int x); |
csyang2 |
1:c0f972361605 | 403 | extern U16 (* GUI__GetCursorPos_pfGetCharacter)(const char * s, int MaxNumChars, int Index, int * pIsRTL); |
csyang2 |
1:c0f972361605 | 404 | |
csyang2 |
1:c0f972361605 | 405 | extern int (* GUI__Wrap_pfGetWordWrap)(const char * s, int xSize, int * pxDist); |
csyang2 |
1:c0f972361605 | 406 | extern int (* GUI__Wrap_pfGetCharWrap)(const char * s, int xSize); |
csyang2 |
1:c0f972361605 | 407 | |
csyang2 |
1:c0f972361605 | 408 | /* Proportional font support */ |
csyang2 |
1:c0f972361605 | 409 | const GUI_FONT_PROP * GUIPROP__FindChar(const GUI_FONT_PROP * pProp, U16P c); |
csyang2 |
1:c0f972361605 | 410 | |
csyang2 |
1:c0f972361605 | 411 | /* Extended proportional font support */ |
csyang2 |
1:c0f972361605 | 412 | const GUI_FONT_PROP_EXT * GUIPROP_EXT__FindChar(const GUI_FONT_PROP_EXT * pPropExt, U16P c); |
csyang2 |
1:c0f972361605 | 413 | void GUIPROP_EXT__DispLine (const char * s, int Len); |
csyang2 |
1:c0f972361605 | 414 | void GUIPROP_EXT__ClearLine (const char * s, int Len); |
csyang2 |
1:c0f972361605 | 415 | void GUIPROP_EXT__SetfpClearLine(void (* fpClearLine)(const char * s, int Len)); |
csyang2 |
1:c0f972361605 | 416 | |
csyang2 |
1:c0f972361605 | 417 | /* Reading data routines */ |
csyang2 |
1:c0f972361605 | 418 | U16 GUI__Read16(const U8 ** ppData); |
csyang2 |
1:c0f972361605 | 419 | U32 GUI__Read32(const U8 ** ppData); |
csyang2 |
1:c0f972361605 | 420 | |
csyang2 |
1:c0f972361605 | 421 | /* Virtual screen support */ |
csyang2 |
1:c0f972361605 | 422 | void GUI__GetOrg(int * px, int * py); |
csyang2 |
1:c0f972361605 | 423 | void GUI__SetOrgHook(void(* pfHook)(int x, int y)); |
csyang2 |
1:c0f972361605 | 424 | |
csyang2 |
1:c0f972361605 | 425 | /* Timer support */ |
csyang2 |
1:c0f972361605 | 426 | int GUI_TIMER__IsActive (void); |
csyang2 |
1:c0f972361605 | 427 | GUI_TIMER_TIME GUI_TIMER__GetPeriod (void); |
csyang2 |
1:c0f972361605 | 428 | GUI_TIMER_HANDLE GUI_TIMER__GetFirstTimer (PTR_ADDR * pContext); |
csyang2 |
1:c0f972361605 | 429 | GUI_TIMER_HANDLE GUI_TIMER__GetNextTimerLin(GUI_TIMER_HANDLE hTimer, PTR_ADDR * pContext); |
csyang2 |
1:c0f972361605 | 430 | |
csyang2 |
1:c0f972361605 | 431 | /* Get function pointers for color conversion */ |
csyang2 |
1:c0f972361605 | 432 | tLCDDEV_Index2Color * GUI_GetpfIndex2ColorEx(int LayerIndex); |
csyang2 |
1:c0f972361605 | 433 | tLCDDEV_Color2Index * GUI_GetpfColor2IndexEx(int LayerIndex); |
csyang2 |
1:c0f972361605 | 434 | |
csyang2 |
1:c0f972361605 | 435 | int GUI_GetBitsPerPixelEx(int LayerIndex); |
csyang2 |
1:c0f972361605 | 436 | |
csyang2 |
1:c0f972361605 | 437 | LCD_PIXELINDEX * LCD_GetpPalConvTable (const LCD_LOGPALETTE * pLogPal); |
csyang2 |
1:c0f972361605 | 438 | LCD_PIXELINDEX * LCD_GetpPalConvTableUncached(const LCD_LOGPALETTE * pLogPal); |
csyang2 |
1:c0f972361605 | 439 | LCD_PIXELINDEX * LCD_GetpPalConvTableBM (const LCD_LOGPALETTE * pLogPal, const GUI_BITMAP * pBitmap, int LayerIndex); |
csyang2 |
1:c0f972361605 | 440 | |
csyang2 |
1:c0f972361605 | 441 | /* Setting a function for converting a color palette to an array of index values */ |
csyang2 |
1:c0f972361605 | 442 | void GUI_SetFuncGetpPalConvTable(LCD_PIXELINDEX * (* pFunc)(const LCD_LOGPALETTE * pLogPal, const GUI_BITMAP * pBitmap, int LayerIndex)); |
csyang2 |
1:c0f972361605 | 443 | |
csyang2 |
1:c0f972361605 | 444 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 445 | * |
csyang2 |
1:c0f972361605 | 446 | * Format definitions used by streamed bitmaps |
csyang2 |
1:c0f972361605 | 447 | * |
csyang2 |
1:c0f972361605 | 448 | * IMPORTANT: DO NOT CHANGE THESE VALUES! |
csyang2 |
1:c0f972361605 | 449 | * THEY HAVE TO CORRESPOND TO THE DEFINITIONS WITHIN THE CODE OF THE BITMAPCONVERTER! |
csyang2 |
1:c0f972361605 | 450 | */ |
csyang2 |
1:c0f972361605 | 451 | #define GUI_STREAM_FORMAT_INDEXED 100 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 452 | #define GUI_STREAM_FORMAT_RLE4 6 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 453 | #define GUI_STREAM_FORMAT_RLE8 7 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 454 | #define GUI_STREAM_FORMAT_565 8 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 455 | #define GUI_STREAM_FORMAT_M565 9 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 456 | #define GUI_STREAM_FORMAT_555 10 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 457 | #define GUI_STREAM_FORMAT_M555 11 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 458 | #define GUI_STREAM_FORMAT_RLE16 12 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 459 | #define GUI_STREAM_FORMAT_RLEM16 13 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 460 | #define GUI_STREAM_FORMAT_8888 16 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 461 | #define GUI_STREAM_FORMAT_RLE32 15 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 462 | #define GUI_STREAM_FORMAT_24 17 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 463 | #define GUI_STREAM_FORMAT_RLEALPHA 18 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 464 | #define GUI_STREAM_FORMAT_444_12 19 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 465 | #define GUI_STREAM_FORMAT_M444_12 20 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 466 | #define GUI_STREAM_FORMAT_444_12_1 21 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 467 | #define GUI_STREAM_FORMAT_M444_12_1 22 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 468 | #define GUI_STREAM_FORMAT_444_16 23 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 469 | #define GUI_STREAM_FORMAT_M444_16 24 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 470 | #define GUI_STREAM_FORMAT_A555 25 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 471 | #define GUI_STREAM_FORMAT_AM555 26 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 472 | #define GUI_STREAM_FORMAT_A565 27 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 473 | #define GUI_STREAM_FORMAT_AM565 28 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 474 | #define GUI_STREAM_FORMAT_M8888I 29 /* DO NOT CHANGE */ |
csyang2 |
1:c0f972361605 | 475 | |
csyang2 |
1:c0f972361605 | 476 | void GUI__ReadHeaderFromStream (GUI_BITMAP_STREAM * pBitmapHeader, const U8 * pData); |
csyang2 |
1:c0f972361605 | 477 | void GUI__CreateBitmapFromStream(const GUI_BITMAP_STREAM * pBitmapHeader, const void * pData, GUI_BITMAP * pBMP, GUI_LOGPALETTE * pPAL, const GUI_BITMAP_METHODS * pMethods); |
csyang2 |
1:c0f972361605 | 478 | |
csyang2 |
1:c0f972361605 | 479 | /* Cache management */ |
csyang2 |
1:c0f972361605 | 480 | int GUI__ManageCache (int Cmd); |
csyang2 |
1:c0f972361605 | 481 | int GUI__ManageCacheEx(int LayerIndex, int Cmd); |
csyang2 |
1:c0f972361605 | 482 | |
csyang2 |
1:c0f972361605 | 483 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 484 | * |
csyang2 |
1:c0f972361605 | 485 | * 2d - GL |
csyang2 |
1:c0f972361605 | 486 | * |
csyang2 |
1:c0f972361605 | 487 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 488 | */ |
csyang2 |
1:c0f972361605 | 489 | void GL_DispChar (U16 c); |
csyang2 |
1:c0f972361605 | 490 | void GL_DrawArc (int x0, int y0, int rx, int ry, int a0, int a1); |
csyang2 |
1:c0f972361605 | 491 | void GL_DrawBitmap (const GUI_BITMAP * pBM, int x0, int y0); |
csyang2 |
1:c0f972361605 | 492 | void GL_DrawCircle (int x0, int y0, int r); |
csyang2 |
1:c0f972361605 | 493 | void GL_DrawEllipse (int x0, int y0, int rx, int ry, int w); |
csyang2 |
1:c0f972361605 | 494 | void GL_DrawHLine (int y0, int x0, int x1); |
csyang2 |
1:c0f972361605 | 495 | void GL_DrawPolygon (const GUI_POINT * pPoints, int NumPoints, int x0, int y0); |
csyang2 |
1:c0f972361605 | 496 | void GL_DrawPoint (int x, int y); |
csyang2 |
1:c0f972361605 | 497 | void GL_DrawLine1 (int x0, int y0, int x1, int y1); |
csyang2 |
1:c0f972361605 | 498 | void GL_DrawLine1Ex (int x0, int y0, int x1, int y1, unsigned * pPixelCnt); |
csyang2 |
1:c0f972361605 | 499 | void GL_DrawLineRel (int dx, int dy); |
csyang2 |
1:c0f972361605 | 500 | void GL_DrawLineTo (int x, int y); |
csyang2 |
1:c0f972361605 | 501 | void GL_DrawLineToEx (int x, int y, unsigned * pPixelCnt); |
csyang2 |
1:c0f972361605 | 502 | void GL_DrawLine (int x0, int y0, int x1, int y1); |
csyang2 |
1:c0f972361605 | 503 | void GL_DrawLineEx (int x0, int y0, int x1, int y1, unsigned * pPixelCnt); |
csyang2 |
1:c0f972361605 | 504 | void GL_MoveTo (int x, int y); |
csyang2 |
1:c0f972361605 | 505 | void GL_FillCircle (int x0, int y0, int r); |
csyang2 |
1:c0f972361605 | 506 | void GL_FillCircleAA (int x0, int y0, int r); |
csyang2 |
1:c0f972361605 | 507 | void GL_FillEllipse (int x0, int y0, int rx, int ry); |
csyang2 |
1:c0f972361605 | 508 | void GL_FillPolygon (const GUI_POINT * pPoints, int NumPoints, int x0, int y0); |
csyang2 |
1:c0f972361605 | 509 | void GL_SetDefault (void); |
csyang2 |
1:c0f972361605 | 510 | |
csyang2 |
1:c0f972361605 | 511 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 512 | * |
csyang2 |
1:c0f972361605 | 513 | * Replacement of memcpy() and memset() |
csyang2 |
1:c0f972361605 | 514 | * |
csyang2 |
1:c0f972361605 | 515 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 516 | */ |
csyang2 |
1:c0f972361605 | 517 | // |
csyang2 |
1:c0f972361605 | 518 | // Configurable function pointers |
csyang2 |
1:c0f972361605 | 519 | // |
csyang2 |
1:c0f972361605 | 520 | extern void * (* GUI__pfMemset)(void * pDest, int Fill, size_t Cnt); |
csyang2 |
1:c0f972361605 | 521 | extern void * (* GUI__pfMemcpy)(void * pDest, const void * pSrc, size_t Cnt); |
csyang2 |
1:c0f972361605 | 522 | |
csyang2 |
1:c0f972361605 | 523 | extern int (* GUI__pfStrcmp)(const char *, const char *); |
csyang2 |
1:c0f972361605 | 524 | extern size_t (* GUI__pfStrlen)(const char *); |
csyang2 |
1:c0f972361605 | 525 | extern char * (* GUI__pfStrcpy)(char *, const char *); |
csyang2 |
1:c0f972361605 | 526 | // |
csyang2 |
1:c0f972361605 | 527 | // Macros for typesave use of function pointers |
csyang2 |
1:c0f972361605 | 528 | // |
csyang2 |
1:c0f972361605 | 529 | #define GUI__MEMSET(pDest, Fill, Cnt) GUI__pfMemset((void *)(pDest), (int)(Fill), (size_t)(Cnt)) |
csyang2 |
1:c0f972361605 | 530 | #define GUI__MEMCPY(pDest, pSrc, Cnt) GUI__pfMemcpy((void *)(pDest), (const void *)(pSrc), (size_t)(Cnt)) |
csyang2 |
1:c0f972361605 | 531 | |
csyang2 |
1:c0f972361605 | 532 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 533 | * |
csyang2 |
1:c0f972361605 | 534 | * Callback pointers for dynamic linkage |
csyang2 |
1:c0f972361605 | 535 | * |
csyang2 |
1:c0f972361605 | 536 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 537 | Dynamic linkage pointers reduces configuration hassles. |
csyang2 |
1:c0f972361605 | 538 | */ |
csyang2 |
1:c0f972361605 | 539 | typedef int GUI_tfTimer(void); |
csyang2 |
1:c0f972361605 | 540 | typedef int WM_tfHandlePID(void); |
csyang2 |
1:c0f972361605 | 541 | |
csyang2 |
1:c0f972361605 | 542 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 543 | * |
csyang2 |
1:c0f972361605 | 544 | * Text rotation |
csyang2 |
1:c0f972361605 | 545 | * |
csyang2 |
1:c0f972361605 | 546 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 547 | */ |
csyang2 |
1:c0f972361605 | 548 | extern GUI_RECT GUI_RectDispString; /* Used by LCD_Rotate...() and GUI_DispStringInRect() */ |
csyang2 |
1:c0f972361605 | 549 | |
csyang2 |
1:c0f972361605 | 550 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 551 | * |
csyang2 |
1:c0f972361605 | 552 | * Flag for setting transparency for 'EXT' fonts |
csyang2 |
1:c0f972361605 | 553 | * |
csyang2 |
1:c0f972361605 | 554 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 555 | */ |
csyang2 |
1:c0f972361605 | 556 | extern U8 GUI__CharHasTrans; |
csyang2 |
1:c0f972361605 | 557 | |
csyang2 |
1:c0f972361605 | 558 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 559 | * |
csyang2 |
1:c0f972361605 | 560 | * Multitasking support |
csyang2 |
1:c0f972361605 | 561 | * |
csyang2 |
1:c0f972361605 | 562 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 563 | */ |
csyang2 |
1:c0f972361605 | 564 | extern int GUITASK__EntranceCnt; |
csyang2 |
1:c0f972361605 | 565 | |
csyang2 |
1:c0f972361605 | 566 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 567 | * |
csyang2 |
1:c0f972361605 | 568 | * Bitmap related functions |
csyang2 |
1:c0f972361605 | 569 | * |
csyang2 |
1:c0f972361605 | 570 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 571 | */ |
csyang2 |
1:c0f972361605 | 572 | |
csyang2 |
1:c0f972361605 | 573 | int GUI_GetBitmapPixelIndex(const GUI_BITMAP * pBMP, unsigned x, unsigned y); |
csyang2 |
1:c0f972361605 | 574 | GUI_COLOR GUI_GetBitmapPixelColor(const GUI_BITMAP * pBMP, unsigned x, unsigned y); |
csyang2 |
1:c0f972361605 | 575 | int GUI_GetBitmapPixelIndexEx(int BitsPerPixel, int BytesPerLine, const U8 * pData, unsigned x, unsigned y); |
csyang2 |
1:c0f972361605 | 576 | |
csyang2 |
1:c0f972361605 | 577 | void GUI__DrawBitmap16bpp (int x0, int y0, int xsize, int ysize, const U8 * pPixel, const LCD_LOGPALETTE * pLogPal, int xMag, int yMag, tLCDDEV_Index2Color * pfIndex2Color, const LCD_API_COLOR_CONV * pColorConvAPI); |
csyang2 |
1:c0f972361605 | 578 | void GUI__DrawBitmapA16bpp(int x0, int y0, int xSize, int ySize, const U8 * pPixel, const LCD_LOGPALETTE * pLogPal, int xMag, int yMag, tLCDDEV_Index2Color * pfIndex2Color); |
csyang2 |
1:c0f972361605 | 579 | void GUI__SetPixelAlpha (int x, int y, U8 Alpha, LCD_COLOR Color); |
csyang2 |
1:c0f972361605 | 580 | LCD_COLOR GUI__MixColors (LCD_COLOR Color, LCD_COLOR BkColor, U8 Intens); |
csyang2 |
1:c0f972361605 | 581 | void GUI__MixColorsBulk (U32 * pFG, U32 * pBG, U32 * pDst, unsigned OffFG, unsigned OffBG, unsigned OffDest, unsigned xSize, unsigned ySize, U8 Intens); |
csyang2 |
1:c0f972361605 | 582 | |
csyang2 |
1:c0f972361605 | 583 | extern const GUI_UC_ENC_APILIST GUI_UC_None; |
csyang2 |
1:c0f972361605 | 584 | |
csyang2 |
1:c0f972361605 | 585 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 586 | * |
csyang2 |
1:c0f972361605 | 587 | * LCDDEV_L0_xxx |
csyang2 |
1:c0f972361605 | 588 | * |
csyang2 |
1:c0f972361605 | 589 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 590 | */ |
csyang2 |
1:c0f972361605 | 591 | #define LCDDEV_L0_Color2Index GUI__apDevice[GUI_pContext->SelLayer]->pColorConvAPI->pfColor2Index |
csyang2 |
1:c0f972361605 | 592 | #define LCDDEV_L0_Index2Color GUI__apDevice[GUI_pContext->SelLayer]->pColorConvAPI->pfIndex2Color |
csyang2 |
1:c0f972361605 | 593 | |
csyang2 |
1:c0f972361605 | 594 | #define LCDDEV_L0_DrawBitmap GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfDrawBitmap |
csyang2 |
1:c0f972361605 | 595 | #define LCDDEV_L0_DrawHLine GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfDrawHLine |
csyang2 |
1:c0f972361605 | 596 | #define LCDDEV_L0_DrawVLine GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfDrawVLine |
csyang2 |
1:c0f972361605 | 597 | #define LCDDEV_L0_DrawPixel GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfDrawPixel |
csyang2 |
1:c0f972361605 | 598 | #define LCDDEV_L0_FillRect GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfFillRect |
csyang2 |
1:c0f972361605 | 599 | #define LCDDEV_L0_GetPixel GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfGetPixel |
csyang2 |
1:c0f972361605 | 600 | #define LCDDEV_L0_GetRect GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfGetRect |
csyang2 |
1:c0f972361605 | 601 | #define LCDDEV_L0_GetPixelIndex GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfGetPixelIndex |
csyang2 |
1:c0f972361605 | 602 | #define LCDDEV_L0_SetPixelIndex GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfSetPixelIndex |
csyang2 |
1:c0f972361605 | 603 | #define LCDDEV_L0_XorPixel GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfXorPixel |
csyang2 |
1:c0f972361605 | 604 | #define LCDDEV_L0_GetDevFunc GUI__apDevice[GUI_pContext->SelLayer]->pDeviceAPI->pfGetDevFunc |
csyang2 |
1:c0f972361605 | 605 | |
csyang2 |
1:c0f972361605 | 606 | void LCD_ReadRect (int x0, int y0, int x1, int y1, LCD_PIXELINDEX * pBuffer, GUI_DEVICE * pDevice); |
csyang2 |
1:c0f972361605 | 607 | void GUI_ReadRect (int x0, int y0, int x1, int y1, LCD_PIXELINDEX * pBuffer, GUI_DEVICE * pDevice); |
csyang2 |
1:c0f972361605 | 608 | void GUI_ReadRectEx(int x0, int y0, int x1, int y1, LCD_PIXELINDEX * pBuffer, GUI_DEVICE * pDevice); |
csyang2 |
1:c0f972361605 | 609 | |
csyang2 |
1:c0f972361605 | 610 | void LCD_ReadRectNoClip(int x0, int y0, int x1, int y1, LCD_PIXELINDEX * pBuffer, GUI_DEVICE * pDevice); |
csyang2 |
1:c0f972361605 | 611 | |
csyang2 |
1:c0f972361605 | 612 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 613 | * |
csyang2 |
1:c0f972361605 | 614 | * Internal color management |
csyang2 |
1:c0f972361605 | 615 | * |
csyang2 |
1:c0f972361605 | 616 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 617 | */ |
csyang2 |
1:c0f972361605 | 618 | typedef struct { |
csyang2 |
1:c0f972361605 | 619 | void (* pfSetColor) (LCD_COLOR Index); |
csyang2 |
1:c0f972361605 | 620 | void (* pfSetBkColor) (LCD_COLOR Index); |
csyang2 |
1:c0f972361605 | 621 | LCD_DRAWMODE (* pfSetDrawMode)(LCD_DRAWMODE dm); |
csyang2 |
1:c0f972361605 | 622 | } LCD_SET_COLOR_API; |
csyang2 |
1:c0f972361605 | 623 | |
csyang2 |
1:c0f972361605 | 624 | extern const LCD_SET_COLOR_API * LCD__pSetColorAPI; |
csyang2 |
1:c0f972361605 | 625 | |
csyang2 |
1:c0f972361605 | 626 | #define LCD__SetBkColorIndex(Index) (*GUI_pContext->LCD_pBkColorIndex = Index) |
csyang2 |
1:c0f972361605 | 627 | #define LCD__SetColorIndex(Index) (*GUI_pContext->LCD_pColorIndex = Index) |
csyang2 |
1:c0f972361605 | 628 | #define LCD__GetBkColorIndex() (*GUI_pContext->LCD_pBkColorIndex) |
csyang2 |
1:c0f972361605 | 629 | #define LCD__GetColorIndex() (*GUI_pContext->LCD_pColorIndex) |
csyang2 |
1:c0f972361605 | 630 | |
csyang2 |
1:c0f972361605 | 631 | /* The following 2 defines are only required for compatibility to older versions of the TTF library */ |
csyang2 |
1:c0f972361605 | 632 | #define LCD_BKCOLORINDEX (*GUI_pContext->LCD_pBkColorIndex) |
csyang2 |
1:c0f972361605 | 633 | #define LCD_COLORINDEX (*GUI_pContext->LCD_pColorIndex) |
csyang2 |
1:c0f972361605 | 634 | |
csyang2 |
1:c0f972361605 | 635 | /********************************************************************* |
csyang2 |
1:c0f972361605 | 636 | * |
csyang2 |
1:c0f972361605 | 637 | * EXTERNs for GL_CORE |
csyang2 |
1:c0f972361605 | 638 | * |
csyang2 |
1:c0f972361605 | 639 | ********************************************************************** |
csyang2 |
1:c0f972361605 | 640 | */ |
csyang2 |
1:c0f972361605 | 641 | extern const GUI_FONT * GUI__pFontDefault; |
csyang2 |
1:c0f972361605 | 642 | extern GUI_COLOR GUI__ColorDefault; |
csyang2 |
1:c0f972361605 | 643 | extern GUI_COLOR GUI__BkColorDefault; |
csyang2 |
1:c0f972361605 | 644 | |
csyang2 |
1:c0f972361605 | 645 | extern GUI_SADDR GUI_CONTEXT * GUI_pContext; |
csyang2 |
1:c0f972361605 | 646 | |
csyang2 |
1:c0f972361605 | 647 | extern GUI_DEVICE * GUI__apDevice[GUI_NUM_LAYERS]; |
csyang2 |
1:c0f972361605 | 648 | |
csyang2 |
1:c0f972361605 | 649 | // |
csyang2 |
1:c0f972361605 | 650 | // Function pointer for converting a palette containing a color array into an index array |
csyang2 |
1:c0f972361605 | 651 | // |
csyang2 |
1:c0f972361605 | 652 | extern LCD_PIXELINDEX * (* GUI_pfGetpPalConvTable)(const LCD_LOGPALETTE * pLogPal, const GUI_BITMAP * pBitmap, int LayerIndex); |
csyang2 |
1:c0f972361605 | 653 | |
csyang2 |
1:c0f972361605 | 654 | // |
csyang2 |
1:c0f972361605 | 655 | // Function pointer for mixing up 2 colors |
csyang2 |
1:c0f972361605 | 656 | // |
csyang2 |
1:c0f972361605 | 657 | extern LCD_COLOR (* GUI__pfMixColors)(LCD_COLOR Color, LCD_COLOR BkColor, U8 Intens); |
csyang2 |
1:c0f972361605 | 658 | |
csyang2 |
1:c0f972361605 | 659 | // |
csyang2 |
1:c0f972361605 | 660 | // Function pointer for mixing up arrays of colors |
csyang2 |
1:c0f972361605 | 661 | // |
csyang2 |
1:c0f972361605 | 662 | extern void (* GUI__pfMixColorsBulk)(U32 * pFG, U32 * pBG, U32 * pDst, unsigned OffFG, unsigned OffBG, unsigned OffDest, unsigned xSize, unsigned ySize, U8 Intens); |
csyang2 |
1:c0f972361605 | 663 | |
csyang2 |
1:c0f972361605 | 664 | // |
csyang2 |
1:c0f972361605 | 665 | // Function pointer for mixing color and gamma values |
csyang2 |
1:c0f972361605 | 666 | // |
csyang2 |
1:c0f972361605 | 667 | extern LCD_COLOR (* LCD_AA_pfMixColors16)(LCD_COLOR Color, LCD_COLOR BkColor, U8 Intens); |
csyang2 |
1:c0f972361605 | 668 | |
csyang2 |
1:c0f972361605 | 669 | // |
csyang2 |
1:c0f972361605 | 670 | // Function pointer for drawing alpha memory devices |
csyang2 |
1:c0f972361605 | 671 | // |
csyang2 |
1:c0f972361605 | 672 | extern GUI_DRAWMEMDEV_FUNC * GUI__pfDrawAlphaMemdevFunc; |
csyang2 |
1:c0f972361605 | 673 | extern GUI_DRAWMEMDEV_FUNC * GUI__pfDrawM565MemdevFunc; |
csyang2 |
1:c0f972361605 | 674 | |
csyang2 |
1:c0f972361605 | 675 | // |
csyang2 |
1:c0f972361605 | 676 | // Function pointer for drawing alpha bitmaps |
csyang2 |
1:c0f972361605 | 677 | // |
csyang2 |
1:c0f972361605 | 678 | extern GUI_DRAWBITMAP_FUNC * GUI__pfDrawAlphaBitmapFunc; |
csyang2 |
1:c0f972361605 | 679 | extern GUI_DRAWBITMAP_FUNC * GUI__pfDrawM565BitmapFunc; |
csyang2 |
1:c0f972361605 | 680 | |
csyang2 |
1:c0f972361605 | 681 | extern U8 GUI__DrawStreamedBitmap; |
csyang2 |
1:c0f972361605 | 682 | |
csyang2 |
1:c0f972361605 | 683 | // |
csyang2 |
1:c0f972361605 | 684 | // API list to be used for MultiBuffering |
csyang2 |
1:c0f972361605 | 685 | // |
csyang2 |
1:c0f972361605 | 686 | extern const GUI_MULTIBUF_API GUI_MULTIBUF_APIList; |
csyang2 |
1:c0f972361605 | 687 | extern const GUI_MULTIBUF_API GUI_MULTIBUF_APIListMasked; |
csyang2 |
1:c0f972361605 | 688 | extern const GUI_MULTIBUF_API_EX GUI_MULTIBUF_APIListEx; |
csyang2 |
1:c0f972361605 | 689 | |
csyang2 |
1:c0f972361605 | 690 | #ifdef GL_CORE_C |
csyang2 |
1:c0f972361605 | 691 | #define GUI_EXTERN |
csyang2 |
1:c0f972361605 | 692 | #else |
csyang2 |
1:c0f972361605 | 693 | #define GUI_EXTERN extern |
csyang2 |
1:c0f972361605 | 694 | #endif |
csyang2 |
1:c0f972361605 | 695 | |
csyang2 |
1:c0f972361605 | 696 | GUI_EXTERN void (* GUI_pfExecAnimations)(void); |
csyang2 |
1:c0f972361605 | 697 | GUI_EXTERN int (* GUI_pfUpdateSoftLayer)(void); |
csyang2 |
1:c0f972361605 | 698 | |
csyang2 |
1:c0f972361605 | 699 | #ifdef WIN32 |
csyang2 |
1:c0f972361605 | 700 | GUI_EXTERN void (* GUI_pfSoftlayerGetPixel)(int x, int y, void * p); |
csyang2 |
1:c0f972361605 | 701 | #endif |
csyang2 |
1:c0f972361605 | 702 | |
csyang2 |
1:c0f972361605 | 703 | GUI_EXTERN void (* GUI_pfHookMTOUCH)(const GUI_MTOUCH_STATE * pState); |
csyang2 |
1:c0f972361605 | 704 | |
csyang2 |
1:c0f972361605 | 705 | GUI_EXTERN const GUI_UC_ENC_APILIST * GUI_pUC_API; /* Unicode encoding API */ |
csyang2 |
1:c0f972361605 | 706 | |
csyang2 |
1:c0f972361605 | 707 | GUI_EXTERN GUI_SADDR char GUI_DecChar; |
csyang2 |
1:c0f972361605 | 708 | GUI_EXTERN GUI_tfTimer * GUI_pfTimerExec; |
csyang2 |
1:c0f972361605 | 709 | GUI_EXTERN WM_tfHandlePID * WM_pfHandlePID; |
csyang2 |
1:c0f972361605 | 710 | GUI_EXTERN void (* GUI_pfDispCharStyle)(U16 Char); |
csyang2 |
1:c0f972361605 | 711 | GUI_EXTERN void (* GUI_pfDispCharLine)(int x0); |
csyang2 |
1:c0f972361605 | 712 | |
csyang2 |
1:c0f972361605 | 713 | GUI_EXTERN int GUI__BufferSize; // Required buffer size in pixels for alpha blending and/or antialiasing |
csyang2 |
1:c0f972361605 | 714 | GUI_EXTERN int GUI_AA__ClipX0; // x0-clipping value for AA module |
csyang2 |
1:c0f972361605 | 715 | |
csyang2 |
1:c0f972361605 | 716 | GUI_EXTERN I8 GUI__aNumBuffers[GUI_NUM_LAYERS]; // Number of buffers used per layer |
csyang2 |
1:c0f972361605 | 717 | GUI_EXTERN U8 GUI__PreserveTrans; |
csyang2 |
1:c0f972361605 | 718 | GUI_EXTERN U8 GUI__IsInitialized; |
csyang2 |
1:c0f972361605 | 719 | |
csyang2 |
1:c0f972361605 | 720 | GUI_EXTERN U8 GUI__NumLayersInUse; |
csyang2 |
1:c0f972361605 | 721 | GUI_EXTERN U32 GUI__LayerMask; |
csyang2 |
1:c0f972361605 | 722 | |
csyang2 |
1:c0f972361605 | 723 | #if GUI_SUPPORT_ROTATION |
csyang2 |
1:c0f972361605 | 724 | GUI_EXTERN const tLCD_APIList * GUI_pLCD_APIList; /* Used for rotating text */ |
csyang2 |
1:c0f972361605 | 725 | #endif |
csyang2 |
1:c0f972361605 | 726 | |
csyang2 |
1:c0f972361605 | 727 | GUI_EXTERN I16 GUI_OrgX, GUI_OrgY; |
csyang2 |
1:c0f972361605 | 728 | |
csyang2 |
1:c0f972361605 | 729 | #undef GUI_EXTERN |
csyang2 |
1:c0f972361605 | 730 | |
csyang2 |
1:c0f972361605 | 731 | #if defined(__cplusplus) |
csyang2 |
1:c0f972361605 | 732 | } |
csyang2 |
1:c0f972361605 | 733 | #endif |
csyang2 |
1:c0f972361605 | 734 | |
csyang2 |
1:c0f972361605 | 735 | #endif /* GUI_PRIVATE_H */ |
csyang2 |
1:c0f972361605 | 736 | |
csyang2 |
1:c0f972361605 | 737 | /*************************** End of file ****************************/ |