mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-14 13:50:13 +00:00
SCUMM: fixed messed up colors in 16bit HE games
(regression from 068b4a5351
)
This commit is contained in:
parent
9b703356e6
commit
03ba1871f7
@ -251,7 +251,7 @@ GdiV2::~GdiV2() {
|
||||
}
|
||||
|
||||
#ifdef USE_RGB_COLOR
|
||||
Gdi16Bit::Gdi16Bit(ScummEngine *vm) : Gdi(vm) {
|
||||
GdiHE16bit::GdiHE16bit(ScummEngine *vm) : GdiHE(vm) {
|
||||
}
|
||||
#endif
|
||||
|
||||
@ -3674,7 +3674,7 @@ void Gdi::unkDecode11(byte *dst, int dstPitch, const byte *src, int height) cons
|
||||
#undef READ_BIT_256
|
||||
|
||||
#ifdef USE_RGB_COLOR
|
||||
void Gdi16Bit::writeRoomColor(byte *dst, byte color) const {
|
||||
void GdiHE16bit::writeRoomColor(byte *dst, byte color) const {
|
||||
WRITE_UINT16(dst, READ_LE_UINT16(_vm->_hePalettes + 2048 + color * 2));
|
||||
}
|
||||
#endif
|
||||
|
@ -430,11 +430,11 @@ public:
|
||||
};
|
||||
|
||||
#ifdef USE_RGB_COLOR
|
||||
class Gdi16Bit : public Gdi {
|
||||
class GdiHE16bit : public GdiHE {
|
||||
protected:
|
||||
virtual void writeRoomColor(byte *dst, byte color) const;
|
||||
public:
|
||||
Gdi16Bit(ScummEngine *vm);
|
||||
GdiHE16bit(ScummEngine *vm);
|
||||
};
|
||||
#endif
|
||||
|
||||
|
@ -114,17 +114,18 @@ ScummEngine::ScummEngine(OSystem *syst, const DetectorResult &dr)
|
||||
_rnd("scumm")
|
||||
{
|
||||
|
||||
#ifdef USE_RGB_COLOR
|
||||
if (_game.features & GF_16BIT_COLOR) {
|
||||
if (_game.platform == Common::kPlatformPCEngine)
|
||||
_gdi = new GdiPCEngine(this);
|
||||
else if (_game.heversion > 0)
|
||||
_gdi = new GdiHE16bit(this);
|
||||
} else
|
||||
#endif
|
||||
if (_game.heversion > 0) {
|
||||
_gdi = new GdiHE(this);
|
||||
} else if (_game.platform == Common::kPlatformNES) {
|
||||
_gdi = new GdiNES(this);
|
||||
#ifdef USE_RGB_COLOR
|
||||
} else if (_game.features & GF_16BIT_COLOR) {
|
||||
if (_game.platform == Common::kPlatformPCEngine)
|
||||
_gdi = new GdiPCEngine(this);
|
||||
else
|
||||
_gdi = new Gdi16Bit(this);
|
||||
#endif
|
||||
} else if (_game.version <= 1) {
|
||||
_gdi = new GdiV1(this);
|
||||
} else if (_game.version == 2) {
|
||||
|
Loading…
Reference in New Issue
Block a user