diff options
author | Eugene Sandulenko | 2007-05-26 16:17:31 +0000 |
---|---|---|
committer | Eugene Sandulenko | 2007-05-26 16:17:31 +0000 |
commit | 83c713d9b445bb67fe1dfcb2c9120184605e636c (patch) | |
tree | f9077884a88595d445f9f9c85f156b502fce5dc6 | |
parent | da8097896efd5e74ff7c50e072238fc89de682ba (diff) | |
download | scummvm-rg350-83c713d9b445bb67fe1dfcb2c9120184605e636c.tar.gz scummvm-rg350-83c713d9b445bb67fe1dfcb2c9120184605e636c.tar.bz2 scummvm-rg350-83c713d9b445bb67fe1dfcb2c9120184605e636c.zip |
Slighty modified patch #1701058: "Correct some graphical glitches for
Brocken Sword 1 Mac"
svn-id: r26942
-rw-r--r-- | engines/sword1/screen.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/engines/sword1/screen.cpp b/engines/sword1/screen.cpp index a3045440f5..9300956f56 100644 --- a/engines/sword1/screen.cpp +++ b/engines/sword1/screen.cpp @@ -136,6 +136,12 @@ void Screen::fnSetPalette(uint8 start, uint16 length, uint32 id, bool fadeUp) { uint8 *palData = (uint8*)_resMan->openFetchRes(id); if (start == 0) // force color 0 to black palData[0] = palData[1] = palData[2] = 0; + + if (SwordEngine::_systemVars.isMac) { // see bug #1701058 + if (start != 0 && start + length == 256) // and force color 255 to black as well + palData[(length-1)*3+0] = palData[(length-1)*3+1] = palData[(length-1)*3+2] = 0; + } + for (uint32 cnt = 0; cnt < length; cnt++) { _targetPalette[(start + cnt) * 4 + 0] = palData[cnt * 3 + 0] << 2; _targetPalette[(start + cnt) * 4 + 1] = palData[cnt * 3 + 1] << 2; @@ -358,8 +364,9 @@ void Screen::draw(void) { for (uint16 cnty = 0; cnty < _scrnSizeY; cnty++) for (uint16 cntx = 0; cntx < _scrnSizeX; cntx++) { - if (*src) - *dest = *src; + if (*src = 0) + if (!SwordEngine::_systemVars.isMac || *src != 255) // see bug #1701058 + *dest = *src; dest++; src++; } |