From 4d30c6f7c91dcf7376cb8a6711b3cc9cdc92012a Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Tue, 15 Feb 2011 23:57:35 +0100 Subject: PSP: Adapt to setPalette/grabPalette RGBA->RGB change. This change is not tested, but should hopefully work fine. --- backends/platform/psp/display_client.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'backends') diff --git a/backends/platform/psp/display_client.cpp b/backends/platform/psp/display_client.cpp index 82e2d17d10..76b4a28e4a 100644 --- a/backends/platform/psp/display_client.cpp +++ b/backends/platform/psp/display_client.cpp @@ -110,7 +110,7 @@ void Palette::setPartial(const byte *colors, uint32 start, uint32 num, bool supp for (uint32 i = 0; i < num; ++i) { byte alphaVal = supportsAlpha ? src[3] : 0xFF; *palette = (uint16)_pixelFormat.rgbaToColor(src[0], src[1], src[2], alphaVal); - src += 4; + src += 3; palette++; } } else if (_pixelFormat.bitsPerPixel == 32) { @@ -120,7 +120,7 @@ void Palette::setPartial(const byte *colors, uint32 start, uint32 num, bool supp for (uint32 i = 0; i < num; ++i) { byte alphaVal = supportsAlpha ? src[3] : 0xFF; *palette = _pixelFormat.rgbaToColor(src[0], src[1], src[2], alphaVal); - src += 4; + src += 3; palette++; } } @@ -214,7 +214,6 @@ void Palette::getPartial(byte *colors, uint start, uint num) { *colors++ = (byte)r; *colors++ = (byte)g; *colors++ = (byte)b; - *colors++ = (byte)a; palette++; } } else if (_pixelFormat.bitsPerPixel == 32) { @@ -227,7 +226,6 @@ void Palette::getPartial(byte *colors, uint start, uint num) { *colors++ = (byte)r; *colors++ = (byte)g; *colors++ = (byte)b; - *colors++ = (byte)a; palette++; } } -- cgit v1.2.3