diff options
author | uruk | 2014-02-05 10:20:46 +0100 |
---|---|---|
committer | uruk | 2014-02-05 10:51:32 +0100 |
commit | 2ca5143155d472f0140ed27d4ec15e4d08655a01 (patch) | |
tree | b7dfe7afd4d717479ed4cf43ba881c200c9f520d /engines/avalanche | |
parent | 89386900bb4b633356da05cd22aac7e4009a28c1 (diff) | |
download | scummvm-rg350-2ca5143155d472f0140ed27d4ec15e4d08655a01.tar.gz scummvm-rg350-2ca5143155d472f0140ed27d4ec15e4d08655a01.tar.bz2 scummvm-rg350-2ca5143155d472f0140ed27d4ec15e4d08655a01.zip |
AVALANCHE: Remove unnecessary checks from picture creatings.
Diffstat (limited to 'engines/avalanche')
-rw-r--r-- | engines/avalanche/graphics.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/engines/avalanche/graphics.cpp b/engines/avalanche/graphics.cpp index dd08eac7f0..2a4a29c1c9 100644 --- a/engines/avalanche/graphics.cpp +++ b/engines/avalanche/graphics.cpp @@ -515,8 +515,7 @@ void GraphicManager::ghostDrawGhost(byte ghostArr[2][66][26], uint16 destX, uint byte pixel = ghostArr[kPlaneToUse[plane]][y][x]; for (int bit = 0; bit < 8; bit++) { byte pixelBit = (pixel >> bit) & 1; - if (pixelBit != 0) - *(byte *)ghostPic.getBasePtr(x * 8 + 7 - bit, y) += (pixelBit << plane); + *(byte *)ghostPic.getBasePtr(x * 8 + 7 - bit, y) += (pixelBit << plane); } } } @@ -541,8 +540,7 @@ void GraphicManager::ghostDrawGlerk(byte glerkArr[4][35][9], uint16 destX, uint1 byte pixel = glerkArr[plane][y][x]; for (int bit = 0; bit < 8; bit++) { byte pixelBit = (pixel >> bit) & 1; - if (pixelBit != 0) - *(byte *)glerkPic.getBasePtr(x * 8 + 7 - bit, y) += (pixelBit << plane); + *(byte *)glerkPic.getBasePtr(x * 8 + 7 - bit, y) += (pixelBit << plane); } } } @@ -640,8 +638,7 @@ Graphics::Surface GraphicManager::loadPictureGraphic(Common::File &file) { byte pixel = file.readByte(); for (int bit = 0; bit < 8; bit++) { byte pixelBit = (pixel >> bit) & 1; - if (pixelBit != 0) - *(byte *)picture.getBasePtr(x + 7 - bit, y) += (pixelBit << plane); + *(byte *)picture.getBasePtr(x + 7 - bit, y) += (pixelBit << plane); } } } @@ -689,8 +686,7 @@ Graphics::Surface GraphicManager::loadPictureSign(Common::File &file, int xl, in byte pixel = file.readByte(); for (int bit = 0; bit < 8; bit++) { byte pixelBit = (pixel >> bit) & 1; - if (pixelBit != 0) - *(byte *)picture.getBasePtr(xx + 7 - bit, yy) += (pixelBit << plane); + *(byte *)picture.getBasePtr(xx + 7 - bit, yy) += (pixelBit << plane); } } } |