diff options
Diffstat (limited to 'backends')
-rw-r--r-- | backends/platform/iphone/osys_main.h | 3 | ||||
-rw-r--r-- | backends/platform/iphone/osys_video.cpp | 3 |
2 files changed, 5 insertions, 1 deletions
diff --git a/backends/platform/iphone/osys_main.h b/backends/platform/iphone/osys_main.h index b89eed9d43..c63ba41319 100644 --- a/backends/platform/iphone/osys_main.h +++ b/backends/platform/iphone/osys_main.h @@ -70,7 +70,10 @@ protected: uint16 *_fullscreen; + // For use with the game texture uint16 _gamePalette[256]; + // For use with the mouse texture + uint16 _gamePaletteRGBA5551[256]; bool _overlayVisible; uint16 _screenWidth; uint16 _screenHeight; diff --git a/backends/platform/iphone/osys_video.cpp b/backends/platform/iphone/osys_video.cpp index c97b6757ea..3b14126234 100644 --- a/backends/platform/iphone/osys_video.cpp +++ b/backends/platform/iphone/osys_video.cpp @@ -99,6 +99,7 @@ void OSystem_IPHONE::setPalette(const byte *colors, uint start, uint num) { for (uint i = start; i < start + num; ++i) { _gamePalette[i] = Graphics::RGBToColor<Graphics::ColorMasks<565> >(b[0], b[1], b[2]); + _gamePaletteRGBA5551[i] = Graphics::RGBToColor<Graphics::ColorMasks<5551> >(b[0], b[1], b[2]); b += 3; } @@ -473,7 +474,7 @@ void OSystem_IPHONE::setMouseCursor(const byte *buf, uint w, uint h, int hotspot for (uint y = 0; y < h; ++y) { byte color = buf[y * w + x]; if (color != keycolor) - mouseBuf[y * texWidth + x] = _gamePalette[color] | 0x1; + mouseBuf[y * texWidth + x] = _gamePaletteRGBA5551[color] | 0x1; else mouseBuf[y * texWidth + x] = 0x0; } |