diff options
Diffstat (limited to 'backends')
-rwxr-xr-x | backends/PalmOS/Src/base_gfx.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/backends/PalmOS/Src/base_gfx.cpp b/backends/PalmOS/Src/base_gfx.cpp index 39555433e0..9496a175b7 100755 --- a/backends/PalmOS/Src/base_gfx.cpp +++ b/backends/PalmOS/Src/base_gfx.cpp @@ -113,6 +113,17 @@ void OSystem_PalmBase::setPalette(const byte *colors, uint start, uint num) { _paletteDirtyEnd = start + num; } +void OSystem_PalmBase::grabPalette(byte *colors, uint start, uint num) { + const RGBColorType *base = _currentPalette + start; + + for (uint i = 0; i < num; ++i) { + colors[i * 4] = base[i].r; + colors[i * 4 + 1] = base[i].g; + colors[i * 4 + 2] = base[i].b; + colors[i * 4 + 3] = 0xFF; + } +} + /* * Screen * |