From mboxrd@z Thu Jan 1 00:00:00 1970 From: Francesco Mandracci Date: Thu, 15 Sep 2005 18:18:14 +0200 Subject: [U-Boot-Users] [PATCH] wrong lcd splashscreen colors (pxa) Message-ID: <43299EC6.6050206@primaelectronics.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello world :) it seems that the computation of colors in common/lcd.c:lcd_display_bitmap() is wrong for green and blue components. I checked on version 1.1.3 and on cvs.sf.net. I'm working on a PXA270 but this seems general (as far as I understand). The error is not evident until you use full colors (i.e. if color RGB components/bytes are either 0x00 of 0xff). ------------------------------------------------------ bmp_color_table_entry_t cte = bmp->color_table[i]; ushort colreg = ( ((cte.red) << 8) & 0xf800) | - ( ((cte.green) << 4) & 0x07e0) | - ( (cte.blue) & 0x001f) ; + ( ((cte.green) << 3) & 0x07e0) | + ( ((cte.blue) >> 3) & 0x001f) ; #ifdef CFG_INVERT_COLORS *cmap = 0xffff - colreg; #else *cmap = colreg; #endif ------------------------------------------------------ Hoping this helps. Ciao Francesco Mandracci PS Thank you all for the great job: it's the first time I get to a bootloader prompt (on a new hardware) after only about 6 hours of work.