From ab039812e7d0a0202317c61a2cb64874e4d0c410 Mon Sep 17 00:00:00 2001 From: Max Horn Date: Mon, 7 Feb 2011 17:52:38 +0000 Subject: COMMON: OSystem now has a PaletteManager svn-id: r55806 --- backends/platform/ds/arm9/source/osystem_ds.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'backends/platform/ds/arm9/source') diff --git a/backends/platform/ds/arm9/source/osystem_ds.h b/backends/platform/ds/arm9/source/osystem_ds.h index 50a4353e18..27d75e5124 100644 --- a/backends/platform/ds/arm9/source/osystem_ds.h +++ b/backends/platform/ds/arm9/source/osystem_ds.h @@ -37,7 +37,7 @@ #include "graphics/surface.h" #include "graphics/colormasks.h" -class OSystem_DS : public BaseBackend { +class OSystem_DS : public BaseBackend, public PaletteManager { protected: int eventNum; @@ -92,8 +92,14 @@ public: virtual void initSize(uint width, uint height, const Graphics::PixelFormat *format); virtual int16 getHeight(); virtual int16 getWidth(); + + virtual PaletteManager *getPaletteManager() { return this; } +protected: + // PaletteManager API virtual void setPalette(const byte *colors, uint start, uint num); - virtual void grabPalette(unsigned char *colors, uint start, uint num); + virtual void grabPalette(byte *colors, uint start, uint num); + +public: void restoreHardwarePalette(); virtual void copyRectToScreen(const byte *buf, int pitch, int x, int y, int w, int h); -- cgit v1.2.3