From 3a64d35dfd9126d7912c4d4496030f7ed120d660 Mon Sep 17 00:00:00 2001 From: Travis Howell Date: Thu, 4 Jun 2009 01:05:47 +0000 Subject: Add 16bit color support for later HE games. svn-id: r41153 --- engines/scumm/scumm.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'engines/scumm/scumm.h') diff --git a/engines/scumm/scumm.h b/engines/scumm/scumm.h index ff3852ee83..c4b2ab9e56 100644 --- a/engines/scumm/scumm.h +++ b/engines/scumm/scumm.h @@ -954,6 +954,7 @@ public: int _screenTop; Common::RenderMode _renderMode; + uint8 _bitDepth; protected: ColorCycle _colorCycle[16]; // Palette cycles @@ -1039,7 +1040,8 @@ protected: virtual void palManipulateInit(int resID, int start, int end, int time); void palManipulate(); public: - int convert16BitColor(uint16 color, uint8 r, uint8 g, uint8 b); + uint8 *getHEPaletteSlot(uint16 palSlot); + uint16 get16BitColor(uint8 r, uint8 g, uint8 b); int remapPaletteColor(int r, int g, int b, int threshold); // Used by Actor::remapActorPalette protected: void moveMemInPalRes(int start, int end, byte direction); @@ -1115,7 +1117,7 @@ public: // HE specific byte _HEV7ActorPalette[256]; uint8 *_hePalettes; - int16 *_hePaletteCache; + uint16 _hePaletteSlot; protected: int _shadowPaletteSize; -- cgit v1.2.3 From f8361b5c53b96faddb56024bb932ce46b7005dbf Mon Sep 17 00:00:00 2001 From: Jody Northup Date: Fri, 5 Jun 2009 06:41:04 +0000 Subject: Converted cursor code to use 16-bit. svn-id: r41191 --- engines/scumm/scumm.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'engines/scumm/scumm.h') diff --git a/engines/scumm/scumm.h b/engines/scumm/scumm.h index c4b2ab9e56..5580c4c73d 100644 --- a/engines/scumm/scumm.h +++ b/engines/scumm/scumm.h @@ -974,7 +974,10 @@ protected: byte animate, animateIndex; int8 state; } _cursor; - byte _grabbedCursor[8192]; + + // HACK Double the array size to handle 16-bit images. + // this should be dynamically allocated based on game depth instead. + byte _grabbedCursor[16384]; byte _currentCursor; byte _newEffect, _switchRoomEffect2, _switchRoomEffect; -- cgit v1.2.3