eGUI alias D4D  Release 3.0
Reference Manual
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
d4d_imgdec_d4d.c
Go to the documentation of this file.
1 /**************************************************************************
2 *
3 * Copyright 2014 by Petr Gargulak. eGUI Community.
4 * Copyright 2009-2013 by Petr Gargulak. Freescale Semiconductor, Inc.
5 *
6 ***************************************************************************
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU Lesser General Public License Version 3
9 * or later (the "LGPL").
10 *
11 * As a special exception, the copyright holders of the eGUI project give you
12 * permission to link the eGUI sources with independent modules to produce an
13 * executable, regardless of the license terms of these independent modules,
14 * and to copy and distribute the resulting executable under terms of your
15 * choice, provided that you also meet, for each linked independent module,
16 * the terms and conditions of the license of that module.
17 * An independent module is a module which is not derived from or based
18 * on this library.
19 * If you modify the eGUI sources, you may extend this exception
20 * to your version of the eGUI sources, but you are not obligated
21 * to do so. If you do not wish to do so, delete this
22 * exception statement from your version.
23 *
24 * This program is distributed in the hope that it will be useful,
25 * but WITHOUT ANY WARRANTY; without even the implied warranty of
26 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
27 *
28 * You should have received a copy of the GNU General Public License
29 * and the GNU Lesser General Public License along with this program.
30 * If not, see <http://www.gnu.org/licenses/>.
31 *
32 ***************************************************************************/
46 #include "d4d.h"
51 
52 #if (D4D_BMP_EXTSRC_SUPPORT_D4D == D4D_TRUE) && (D4D_EXTSRC_FILE_ENABLE == D4D_TRUE)
53 
54 #if D4D_BMP_PAL_2_ENABLE != D4D_FALSE
55  extern D4D_COLOR D4D_GetPixel_BmpDecodeBmp2(D4D_D4DBMP_DECODE* pDecode);
56 #endif
57 
58 #if D4D_BMP_PAL_16_ENABLE != D4D_FALSE
59  extern D4D_COLOR D4D_GetPixel_BmpDecodeBmp16(D4D_D4DBMP_DECODE* pDecode);
60 #endif
61 
62 #if (D4D_BMP_256NOPAL_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_256_ENABLE != D4D_FALSE)
63  extern D4D_COLOR D4D_GetPixel_BmpDecodeBmp256(D4D_D4DBMP_DECODE* pDecode);
64 #endif
65 
66 #if (D4D_BMP_65536NOPAL_ENABLE != D4D_FALSE)
67  extern D4D_COLOR D4D_GetPixel_BmpDecodeBmp65K(D4D_D4DBMP_DECODE* pDecode);
68 #endif
69 
70 #if (D4D_BMP_256KNOPAL_ENABLE != D4D_FALSE)
71  extern D4D_COLOR D4D_GetPixel_BmpDecodeBmp256K(D4D_D4DBMP_DECODE* pDecode);
72 #endif
73 
74 #if (D4D_BMP_16MNOPAL_ENABLE != D4D_FALSE)
75  extern D4D_COLOR D4D_GetPixel_BmpDecodeBmp16M(D4D_D4DBMP_DECODE* pDecode);
76 #endif
77 
78 #if (D4D_BMP_16MNOPAL_ENABLE != D4D_FALSE) || (D4D_BMP_256KNOPAL_ENABLE != D4D_FALSE)
79  static LWord D4D_GetDataLong(D4D_D4DBMP_DECODE* pDecode, D4D_BOOL increment);
80 #endif
81 
82 #if (D4D_BMP_65536NOPAL_ENABLE != D4D_FALSE)
83  static Word D4D_GetDataWord(D4D_D4DBMP_DECODE* pDecode, D4D_BOOL increment);
84 #endif
85 
86 #if (D4D_BMP_256NOPAL_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_256_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_16_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_2_ENABLE != D4D_FALSE)
87  static Byte D4D_GetDataByte(D4D_D4DBMP_DECODE* pDecode, D4D_BOOL increment);
88 #endif
89 
90 
91 void D4D_ImgDecExtD4DDraw(D4D_COOR x, D4D_COOR y, D4D_CHAR* pFileName, D4D_BOOL greyScale, D4D_COOR radius)
92 {
93  D4D_FILEPTR pFile;
94  D4D_D4DBMP_DECODE d4dbmp_decode;
95  LWord cmode;
96  D4D_COOR x2;
97  D4D_COOR y2;
98  D4D_COOR width;
99  D4D_COOR height;
100  LWord x_ix, y_ix;
101 
102  // open the picture file
103  pFile = D4D_OpenImgFile(pFileName, "r");
104 
105  // check if the file is opened
106  if(pFile == NULL)
107  return;
108 
109  // load the header of picture file
110 
111  #ifdef D4D_DEBUG
112  // sanity check
114  #endif
115 
117  {
118  // the header isn't loaded succesfully
119  D4D_FileClose(pFile);
120  return;
121  }
122  #if D4D_ENDIAN == D4D_ENDIAN_LITTLE
123  if(d4d_extsrcBuffer[6] != 'L')
124  #else
125  if(d4d_extsrcBuffer[6] != 'B')
126  #endif
127  {
128  //the content doesn't match the excepted content
129  D4D_FileClose(pFile);
130  return;
131  }
132 
133  d4d_extsrcBuffer[6] = '\0';
134 
135  // check the content of file - is really D4D picture binary format?
136  if(D4D_CompareStrings((const D4D_CHAR*)(&((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->ident), "D4DBMP"))
137  {
138  //the content doesn't match the excepted content
139  D4D_FileClose(pFile);
140  return;
141  }
142 
143  // check the version of D4DBMP header
144  if(((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->version > 1)
145  {
146  //the current version of D4DBMP file is not supported
147  D4D_FileClose(pFile);
148  return;
149  }
150 
151  width = ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->width;
152  height = ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->height;
153 
154  x2 = (D4D_COOR)(x + width - 1);
155  y2 = (D4D_COOR)(y + height - 1);
156 
157  if(((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->version)
158  cmode = ((D4D_EXTSRC_HEADER_D4D_1*)d4d_extsrcBuffer)->colorMode; // color mode in version
159  else
160  cmode = ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->colorMode; // color mode in version
161 
162  d4dbmp_decode.ix = 0;
163  d4dbmp_decode.rptCnt = 0;
164  d4dbmp_decode.curSubPxl = 0;
165  d4dbmp_decode.compress = (cmode & D4D_BMP_COMPRESS_MASK);
166  d4dbmp_decode.greyScale = greyScale;
167  d4dbmp_decode.pBmp = NULL;
168  d4dbmp_decode.dataCnt = 0;
169  d4dbmp_decode.dataIx = 0;
170  d4dbmp_decode.pFile = pFile;
171 
172  // There is also pallete
173  if(((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->palleteOffset && ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->palleteSize)
174  {
175  // alloc the memory for pallete
176  d4dbmp_decode.pPalette = D4D_MemAlloc(((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->palleteSize);
177  if(d4dbmp_decode.pPalette == NULL)
178  {
179  // the Bitmap pallete isn't loaded succesfully
180  D4D_FileClose(pFile);
181  return;
182  }
183 
184  if(D4D_FileSeek(pFile, ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->palleteOffset, D4D_SEEK_SET) != 0)
185  {
186  // the position in file can't be sets
187  D4D_MemFree((void*)d4dbmp_decode.pPalette);
188  D4D_FileClose(pFile);
189  return;
190  }
191 
192  // load the Bitmap pallete
193  if(D4D_FileRead(pFile, (void*)d4dbmp_decode.pPalette, ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->palleteSize) != ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->palleteSize)
194  {
195  // the Bitmap pallete isn't loaded succesfully
196  D4D_MemFree((void*)d4dbmp_decode.pPalette);
197  D4D_FileClose(pFile);
198  return;
199  }
200  }else
201  d4dbmp_decode.pPalette = NULL;
202 
203  switch(cmode & (D4D_BMP_TYPE_MASK | D4D_BMP_CLR_DEPTH_MASK))
204  {
205 #if (D4D_BMP_16MNOPAL_ENABLE != D4D_FALSE)
206  case D4D_BMP_16MNOPAL:
207  d4dbmp_decode.GetPxlDecoder = D4D_GetPixel_BmpDecodeBmp16M;
208  d4dbmp_decode.GetDataFunc = (void*)D4D_GetDataLong;
209  break;
210 #endif
211 
212 
213 #if (D4D_BMP_256KNOPAL_ENABLE != D4D_FALSE)
214  case D4D_BMP_256KNOPAL:
215  d4dbmp_decode.GetPxlDecoder = D4D_GetPixel_BmpDecodeBmp256K;
216  d4dbmp_decode.GetDataFunc = (void*)D4D_GetDataLong;
217  break;
218 #endif
219 
220 #if (D4D_BMP_65536NOPAL_ENABLE != D4D_FALSE)
221  case D4D_BMP_65536NOPAL:
222  d4dbmp_decode.GetPxlDecoder = D4D_GetPixel_BmpDecodeBmp65K;
223  d4dbmp_decode.GetDataFunc = (void*)D4D_GetDataWord;
224  break;
225 #endif
226 
227 #if (D4D_BMP_256NOPAL_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_256_ENABLE != D4D_FALSE)
228  case D4D_BMP_256NOPAL:
229  case D4D_BMP_PAL_256:
230  d4dbmp_decode.GetPxlDecoder = D4D_GetPixel_BmpDecodeBmp256;
231  d4dbmp_decode.GetDataFunc = (void*)D4D_GetDataByte;
232  break;
233 #endif
234 
235 #if D4D_BMP_PAL_16_ENABLE != D4D_FALSE
236  case D4D_BMP_PAL_16:
237  d4dbmp_decode.GetPxlDecoder = D4D_GetPixel_BmpDecodeBmp16;
238  d4dbmp_decode.GetDataFunc = (void*)D4D_GetDataByte;
239  break;
240 #endif
241 
242 #if D4D_BMP_PAL_2_ENABLE != D4D_FALSE
243  case D4D_BMP_PAL_2:
244  d4dbmp_decode.GetPxlDecoder = D4D_GetPixel_BmpDecodeBmp2;
245  d4dbmp_decode.GetDataFunc = (void*)D4D_GetDataByte;
246  break;
247 #endif
248 
249  default:
250  // there are all non supported bitmaps
251  d4dbmp_decode.GetPxlDecoder = NULL;
252  d4dbmp_decode.GetDataFunc = NULL;
253  break;
254  }
255 
256 
257  // set up the position in file on start of data
258  if(D4D_FileSeek(pFile, ((D4D_EXTSRC_HEADER_D4D*)d4d_extsrcBuffer)->dataOffset, D4D_SEEK_SET) != 0)
259  {
260  if(d4dbmp_decode.pPalette)
261  D4D_MemFree((void*)d4dbmp_decode.pPalette);
262 
263  D4D_FileClose(pFile);
264  return;
265  }
266 
267 #if D4D_ROUND_CORNER_ENABLE == D4D_TRUE
268  if(radius)
269  {
270  LWord non_print_len;
271 
272  if(!d4dbmp_decode.GetPxlDecoder)
273  {
275  D4D_MoveToXY((D4D_COOR)(x + radius /2), (D4D_COOR)(y + radius /2));
276 
277  D4D_LineToXY((D4D_COOR)(x2 + radius /2), (D4D_COOR)(y2 + radius /2), D4D_LINE_THIN, D4D_ScreenGetScheme(D4D_GetActiveScreen())->fore);
278 
279  D4D_MoveToXY((D4D_COOR)(x + radius /2), (D4D_COOR)(y2 + radius /2));
280  D4D_LineToXY((D4D_COOR)(x2 + radius /2), (D4D_COOR)(y + radius /2), D4D_LINE_THIN, D4D_ScreenGetScheme(D4D_GetActiveScreen())->fore);
281 
282  if(d4dbmp_decode.pPalette)
283  D4D_MemFree((void*)d4dbmp_decode.pPalette);
284 
285  D4D_FileClose(pFile);
286 
287  return;
288  }
289  // the main drawing function
290  for (y_ix = 0; y_ix < height; ++y_ix) // do for all lines
291  {
292  if(y_ix < radius)
293  non_print_len = D4D_RndCornerGetNonPrintedPxl(radius, (D4D_COOR)(y_ix)); // get len of non printed pixels
294  else if(((y2 - y) - y_ix) < radius)
295  non_print_len = D4D_RndCornerGetNonPrintedPxl(radius, (D4D_COOR)((y2 - y) - y_ix)); // get len of non printed pixels
296  else
297  non_print_len = 0;
298 
299  (void)D4D_LLD_LCD.D4DLCD_SetWindow ((D4D_COOR)(x + non_print_len), (D4D_COOR)(y + y_ix), (D4D_COOR)(x2 - non_print_len + 1), (D4D_COOR)(y + y_ix + 1));
300 
301  for (x_ix = 0; x_ix < width; ++x_ix) // do for all pixels on line
302  {
303 
304  if((x_ix >= non_print_len) && (x_ix <= ((x2 - x) - non_print_len)))
305  D4D_LLD_LCD.D4DLCD_Send_PixelColor(d4dbmp_decode.GetPxlDecoder(&d4dbmp_decode)); // and send color to display
306  else
307  d4dbmp_decode.GetPxlDecoder(&d4dbmp_decode); // just dummy read from file
308  }
309  }
310  }else
311 #else
312  D4D_UNUSED(radius);
313 #endif
314  {
315  if(!d4dbmp_decode.GetPxlDecoder)
316  {
319 
320  D4D_MoveToXY(x, y2);
322 
323  if(d4dbmp_decode.pPalette)
324  D4D_MemFree((void*)d4dbmp_decode.pPalette);
325 
326  D4D_FileClose(pFile);
327  return;
328  }
329  // Define window
330  (void)D4D_LLD_LCD.D4DLCD_SetWindow (x, y, x2, y2);
331 
332  x_ix = (LWord) (width * height); // Count the overall pixel count
333 
334  // the main drawing function
335  for (y_ix=0; y_ix<x_ix; ++y_ix) // do for all pixels
336  D4D_LLD_LCD.D4DLCD_Send_PixelColor(d4dbmp_decode.GetPxlDecoder(&d4dbmp_decode)); // write same pixels to display
337  }
338 #if D4D_LLD_FLUSH_ELEMENT != D4D_FALSE
340 #endif
341  if(d4dbmp_decode.pPalette)
342  D4D_MemFree((void*)d4dbmp_decode.pPalette);
343 
344  D4D_FileClose(pFile);
345 }
346 
347 /**************************************************************/
352 #if (D4D_BMP_16MNOPAL_ENABLE != D4D_FALSE) || (D4D_BMP_256KNOPAL_ENABLE != D4D_FALSE)
353 static LWord D4D_GetDataLong(D4D_D4DBMP_DECODE* pDecode, D4D_BOOL increment)
354 {
355  LWord ret;
356 
357  if(pDecode->dataIx >= (pDecode->dataCnt / 4))
358  {
360 
361  if(pDecode->dataCnt == 0)
362  return 0;
363 
364  pDecode->dataIx = 0;
365  }
366 
367  ret = ((LWord*)d4d_extsrcBuffer)[pDecode->dataIx];
368 
369  if(increment)
370  {
371  pDecode->ix++;
372  pDecode->dataIx++;
373  }
374 
375  return ret;
376 }
377 #endif
378 
379 #if (D4D_BMP_65536NOPAL_ENABLE != D4D_FALSE)
380 static Word D4D_GetDataWord(D4D_D4DBMP_DECODE* pDecode, D4D_BOOL increment)
381 {
382  Word ret;
383 
384  if(pDecode->dataIx >= (pDecode->dataCnt / 2))
385  {
387 
388  if(pDecode->dataCnt == 0)
389  return 0;
390 
391  pDecode->dataIx = 0;
392  }
393 
394  ret = ((Word*)d4d_extsrcBuffer)[pDecode->dataIx];
395 
396  if(increment)
397  {
398  pDecode->ix++;
399  pDecode->dataIx++;
400  }
401 
402  return ret;
403 }
404 #endif
405 
406 #if (D4D_BMP_256NOPAL_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_256_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_16_ENABLE != D4D_FALSE) || (D4D_BMP_PAL_2_ENABLE != D4D_FALSE)
407 static Byte D4D_GetDataByte(D4D_D4DBMP_DECODE* pDecode, D4D_BOOL increment)
408 {
409  Byte ret;
410 
411  if(pDecode->dataIx >= pDecode->dataCnt)
412  {
414 
415  if(pDecode->dataCnt == 0)
416  return 0;
417 
418  pDecode->dataIx = 0;
419  }
420 
421  ret = ((Byte*)d4d_extsrcBuffer)[pDecode->dataIx];
422 
423  if(increment)
424  {
425  pDecode->ix++;
426  pDecode->dataIx++;
427  }
428 
429  return ret;
430 }
431 #endif
432 
433 
434 /**************************************************************/
440 {
441  D4D_SIZE tmp_size = D4D_ImgDecExtD4DGetSize(pFileName);
442 
443  return tmp_size.cx;
444 }
445 
446 /**************************************************************/
452 {
453  D4D_SIZE tmp_size = D4D_ImgDecExtD4DGetSize(pFileName);
454 
455  return tmp_size.cy;
456 }
457 
458 
459 /**************************************************************/
465 {
466  D4D_FILEPTR pFile;
467  D4D_SIZE tmp_size = *(D4D_SIZE*)&d4d_size_zero;
468  int res;
469 
470  // open the picture file
471  pFile = D4D_OpenImgFile(pFileName, "r");
472 
473  // check if the file is opened
474  if(pFile == NULL)
475  return tmp_size;
476 
477  // set up the position in file on start of coordination overjump the version strings (to do_ is it correct?)
478  if(D4D_FileSeek(pFile, 8, D4D_SEEK_SET) != 0)
479  {
480  // the position in file can't be sets
481  D4D_FileClose(pFile);
482  return tmp_size;
483  }
484 
485 
486  res = D4D_FileRead(pFile, d4d_extsrcBuffer, 4);
487 
488  D4D_FileClose(pFile);
489 
490  if(res == 4)
491  {
492  tmp_size.cx = D4D_READ16L(((Word*)d4d_extsrcBuffer)[0]);
493  tmp_size.cy = D4D_READ16L(((Word*)d4d_extsrcBuffer)[1]);
494 
495  }
496  return tmp_size;
497 
498 
499 }
500 
501 /**************************************************************/
506 int D4D_ImgDecExtD4DGetHeader(D4D_CHAR* pFileName, void* pBuff, int max_size)
507 {
508  D4D_FILEPTR pFile;
509  int res;
510 
511  if(max_size < D4D_EXTSRC_HEADER_D4D_SIZE)
512  return 0;
513 
514  // open the picture file
515  pFile = D4D_OpenImgFile(pFileName, "r");
516 
517  // check if the file is opened
518  if(pFile == NULL)
519  return 0;
520 
521  // load the header of picture file
522 
523  res = D4D_FileRead(pFile, pBuff, D4D_EXTSRC_HEADER_D4D_SIZE);
524 
525  D4D_FileClose(pFile);
526 
527  return res;
528 }
529 
530 #endif
531 
D4D driver external pictures d4d decoder functions header file.
void D4D_RBoxXY(D4D_COOR x1, D4D_COOR y1, D4D_COOR x2, D4D_COOR y2, D4D_LINETYPE ltype, D4D_COLOR colorLine, D4D_COLOR colorFill, D4D_COOR radius)
Function draw filled rectangle with outline on the screen with round corners.
#define D4D_MemAlloc(size)
Mem Alloc eGUI definition. If not defined by user config any special user function, it used standard system function.
Definition: d4d_extsrc.h:320
void(* D4DLCD_FlushBuffer)(D4DLCD_FLUSH_MODE mode)
The LCD driver flush function.
Definition: d4d_lldapi.h:154
#define D4D_BMP_PAL_16
#define D4D_READ16L(x)
Macro for handling endianism - read 16bit - from Little Endian.
Definition: d4d_extsrc.h:247
The flush after one basic element is draw.
Definition: d4d_lldapi.h:138
D4D_COOR D4D_ImgDecExtD4DGetHeight(D4D_CHAR *pFileName)
void D4D_MoveToXY(D4D_COOR x, D4D_COOR y)
Function move logic cursor to new position.
D4D Driver main header file.
#define D4D_BMP_CLR_DEPTH_MASK
int D4D_ImgDecExtD4DGetHeader(D4D_CHAR *pFileName, void *pBuff, int max_size)
const D4D_SIZE d4d_size_zero
Definition: d4d_base.c:74
D4D Driver private header file.
D4D_COOR cx
Size in axis X (width)
Definition: d4d_types.h:232
Byte D4D_COOR
Type definition of eGUI coordination variables.
Definition: d4d_types.h:219
#define D4D_BMP_256NOPAL
#define D4D_BMP_TYPE_MASK
unsigned char Byte
Type definition of Byte (unsigned 8-bit).
Definition: d4d_types.h:151
#define D4D_BMP_16MNOPAL
D4D_CLR_SCHEME * D4D_ScreenGetScheme(D4D_SCREEN *pScreen)
#define D4D_BMP_PAL_256
#define D4D_EXTSRC_BUFF_SIZE
This macro is used to specify size of buffer that is using when external file support is enabled...
Definition: d4d_base.h:167
D4D_COOR D4D_ImgDecExtD4DGetWidth(D4D_CHAR *pFileName)
#define NULL
Type definition of null pointer.
Definition: d4d_types.h:184
#define D4D_ASSERT(cond)
Definition: d4d_base.h:583
#define D4D_MemFree(pMem)
Mem Free eGUI definition. If not defined by user config any special user function, it used standard system function.
Definition: d4d_extsrc.h:329
void D4D_BoxXY(D4D_COOR x1, D4D_COOR y1, D4D_COOR x2, D4D_COOR y2, D4D_LINETYPE ltype, D4D_COLOR colorLine, D4D_COLOR colorFill)
Function draw filled rectangle with outline on the screen.
unsigned long LWord
Type definition of LWord (unsigned 32-bit).
Definition: d4d_types.h:167
D4D_SCREEN * D4D_GetActiveScreen(void)
Returns pointer to current active screen.
Definition: d4d_screen.c:78
void D4D_ImgDecExtD4DDraw(D4D_COOR x, D4D_COOR y, D4D_CHAR *pFileName, D4D_BOOL greyScale, D4D_COOR radius)
D4D_COOR D4D_RndCornerGetNonPrintedPxl(D4D_COOR radius, D4D_COOR line)
Function that counts number of printed pixels in specified line of circle quadrant.
#define D4D_EXTSRC_HEADER_D4D_SIZE
#define D4D_BMP_65536NOPAL
#define D4D_SEEK_SET
D4D_SEEK_SET eGUI Origin constant for begin of file (1)
Definition: d4d_extsrc.h:139
D4D driver external pictures d4d decoder functions header file.
D4D_SIZE D4D_ImgDecExtD4DGetSize(D4D_CHAR *pFileName)
D4D_COOR cy
Size in axis Y (height)
Definition: d4d_types.h:233
#define D4D_FileClose
Macro used as short cut to used File Close function defined by D4D_DECLARE_FILE_FUNCTIONS.
Definition: d4d_extsrc.h:305
const D4DLCD_FUNCTIONS D4D_LLD_LCD
LWord D4D_BOOL
Type definition of eGUI boolean.
Definition: d4d_types.h:204
#define D4D_UNUSED(x)
Macro used just for notify compiler that the input parameter is not used.
Definition: d4d_base.h:504
char D4D_CHAR
Type definition of eGUI ASCII character.
Definition: d4d_types.h:280
Type definition of eGUI size structure.
Definition: d4d_types.h:230
#define D4D_BMP_PAL_2
#define D4D_FileSeek
Macro used as short cut to used File Seek function defined by D4D_DECLARE_FILE_FUNCTIONS.
Definition: d4d_extsrc.h:311
int D4D_CompareStrings(const D4D_CHAR *s1, const D4D_CHAR *s2)
The function copare two strings (terminated by zero)
Definition: d4d_extsrc.c:257
Line type thin.
Definition: d4d_types.h:293
Byte d4d_extsrcBuffer[D4D_EXTSRC_BUFF_SIZE]
D4D driver - resistive touch screen driver function header file.
void(* D4DLCD_Send_PixelColor)(D4D_COLOR value)
The LCD driver send pixel function. The pixels will be draw on position (automaticaly incremented) se...
Definition: d4d_lldapi.h:152
void D4D_LineToXY(D4D_COOR x, D4D_COOR y, D4D_LINETYPE ltype, D4D_COLOR color)
Function draw line on the screen.
#define D4D_BMP_256KNOPAL
LWord D4D_COLOR
Type definition of eGUI color variables.
Definition: d4d_types.h:262
#define D4D_BMP_COMPRESS_MASK
unsigned short Word
Type definition of Word (unsigned 16-bit).
Definition: d4d_types.h:159
void * D4D_FILEPTR
Type definition of eGUI file pointer.
Definition: d4d_types.h:298
D4D_COLOR(* GetPxlDecoder)(struct D4D_D4DBMP_DECODE_S *pDecode)
#define D4D_FileRead
Macro used as short cut to used File Read function defined by D4D_DECLARE_FILE_FUNCTIONS.
Definition: d4d_extsrc.h:307
unsigned char(* D4DLCD_SetWindow)(unsigned short x1, unsigned short y1, unsigned short x2, unsigned short y2)
The LCD driver Set logic window function. Into this logic window will be draw pixels.
Definition: d4d_lldapi.h:150