From fd778e3e406a7e83536ea66776996f032f24af64 Mon Sep 17 00:00:00 2001 From: Tony Kuo Date: Thu, 5 Feb 2015 21:25:56 +0800 Subject: Fix Droid and animation color in recovery mode [Problem] Droid and animation color in recovery mode are incorrect [Modify] - Add support for flipping (zero copy) with RECOVERY_ABGR. - Decodes PNG files to BGRA directly, and other fills, text and alpha blending are also done directly in BGRA (i.e. blits can still bypass conversion) - Remove the BGRA workaround added previous for single buffer mode (f766396) Bug:19216535 Change-Id: Ie864419fc6da776ff58b2d02e130f203c194500f Signed-off-by: Tony Kuo --- minui/graphics.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'minui/graphics.c') diff --git a/minui/graphics.c b/minui/graphics.c index ec39433b8..870ffa089 100644 --- a/minui/graphics.c +++ b/minui/graphics.c @@ -161,10 +161,17 @@ void gr_texticon(int x, int y, GRSurface* icon) { void gr_color(unsigned char r, unsigned char g, unsigned char b, unsigned char a) { +#if defined(RECOVERY_ABGR) || defined(RECOVERY_BGRA) + gr_current_r = b; + gr_current_g = g; + gr_current_b = r; + gr_current_a = a; +#else gr_current_r = r; gr_current_g = g; gr_current_b = b; gr_current_a = a; +#endif } void gr_clear() -- cgit v1.2.3