kumquat-buildroot/package/fbv/0003-fix-24bpp-support-on-big-endian.patch
Peter Korsgaard 298cd8eaa2 package/*: rename patches according to the new policy
Autogenerated from rename-patch.py (http://patchwork.ozlabs.org/patch/403345)

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2015-02-03 14:52:56 +01:00

33 lines
1.1 KiB
Diff

diff -upr a/fb_display.c b/fb_display.c
--- a/fb_display.c 2007-06-01 16:52:45.000000000 +0200
+++ b/fb_display.c 2007-06-01 16:51:43.000000000 +0200
@@ -307,7 +307,7 @@ void* convertRGB2FB(int fh, unsigned cha
{
unsigned long i;
void *fbbuff = NULL;
- u_int8_t *c_fbbuff;
+ u_int8_t *c_fbbuff;
u_int16_t *s_fbbuff;
u_int32_t *i_fbbuff;
@@ -335,6 +335,16 @@ void* convertRGB2FB(int fh, unsigned cha
fbbuff = (void *) s_fbbuff;
break;
case 24:
+ *cpp = 3;
+ c_fbbuff = (unsigned char *) malloc(count * 3 * sizeof(unsigned char));
+ for(i = 0; i < (3 * count); i += 3) {
+ /* Big endian framebuffer. */
+ c_fbbuff[i] = rgbbuff[i+2];
+ c_fbbuff[i+1] = rgbbuff[i+1];
+ c_fbbuff[i+2] = rgbbuff[i];
+ }
+ fbbuff = (void *) c_fbbuff;
+ break;
case 32:
*cpp = 4;
i_fbbuff = (unsigned int *) malloc(count * sizeof(unsigned int));
Only in build_avr32/fbv-1.0b-modified: .fb_display.c.swp
Binary files build_avr32/fbv-1.0b/fb_display.o and build_avr32/fbv-1.0b-modified/fb_display.o differ
Binary files build_avr32/fbv-1.0b/fbv and build_avr32/fbv-1.0b-modified/fbv differ