From a1842c04f9cb73210d4cacde61a9e4b115050765 Mon Sep 17 00:00:00 2001 From: Thomas Martitz Date: Wed, 18 Jun 2014 07:15:00 +0200 Subject: lcd-24bit: Introduce a 24-bit mid-level LCD driver With LCD driver all calculation will be performed on RGB888 and the hardware/OS can display from our 24bit framebuffer. It is not yet as performance optimized as the existing drivers but should be good enough.The vast number of small changes is due to the fact that fb_data can be a struct type now, while most of the code expected a scalar type. lcd-as-memframe ASM code does not work with 24bit currently so the with 24bit it enforces the generic C code. All plugins are ported over. Except for rockpaint. It uses so much memory that it wouldnt fit into the 512k plugin buffer anymore (patches welcome). Change-Id: Ibb1964545028ce0d8ff9833ccc3ab66be3ee0754 --- firmware/screendump.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'firmware/screendump.c') diff --git a/firmware/screendump.c b/firmware/screendump.c index 28c37610af..2916cc1c9f 100644 --- a/firmware/screendump.c +++ b/firmware/screendump.c @@ -118,6 +118,9 @@ void screen_dump(void) #elif LCD_DEPTH <= 16 unsigned short *dst, *dst_end; unsigned short linebuf[DUMP_BMP_LINESIZE/2]; +#else /* 24bit */ + unsigned char *dst, *dst_end; + unsigned char linebuf[DUMP_BMP_LINESIZE * 3]; #endif #if CONFIG_RTC @@ -227,6 +230,17 @@ void screen_dump(void) #endif } while (dst < dst_end); +#elif LCD_DEPTH == 24 + dst_end = dst + LCD_WIDTH*3; + src = FBADDR(0, y); + do + { + *dst++ = src->b; + *dst++ = src->g; + *dst++ = src->r; + ++src; + } + while (dst < dst_end); #endif /* LCD_DEPTH */ write(fd, linebuf, DUMP_BMP_LINESIZE); -- cgit v1.2.3