aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authoruruk2013-07-26 14:52:26 +0200
committeruruk2013-07-26 14:52:26 +0200
commit190e37d3f9f7b990722163df5aae247fdbe8688c (patch)
tree7099fb670c2b61339c2b83cdd9dd2f4a3ef514e6 /engines
parentff1bc9e5a54061b2eb9edd4975f05b5f88b0fca0 (diff)
downloadscummvm-rg350-190e37d3f9f7b990722163df5aae247fdbe8688c.tar.gz
scummvm-rg350-190e37d3f9f7b990722163df5aae247fdbe8688c.tar.bz2
scummvm-rg350-190e37d3f9f7b990722163df5aae247fdbe8688c.zip
AVALANCHE: Remove Graphics::drawPicture_old().
Diffstat (limited to 'engines')
-rw-r--r--engines/avalanche/graphics.cpp30
-rw-r--r--engines/avalanche/graphics.h2
2 files changed, 0 insertions, 32 deletions
diff --git a/engines/avalanche/graphics.cpp b/engines/avalanche/graphics.cpp
index 1b5d686b0a..12b94fe175 100644
--- a/engines/avalanche/graphics.cpp
+++ b/engines/avalanche/graphics.cpp
@@ -169,36 +169,6 @@ void Graphics::drawPicture(const ::Graphics::Surface &picture, uint16 destX, uin
*getPixel(x + destX, y + destY) = *(byte *)picture.getBasePtr(x, y);
}
-void Graphics::drawPicture_old(const byte *source, uint16 destX, uint16 destY) {
- // The height and the width are stored in 2-2 bytes. We have to add 1 to each because Pascal stores the value of them -1.
- uint16 pictureWidth = READ_LE_UINT16(source) + 1;
- uint16 pictureHeight = READ_LE_UINT16(source + 2) + 1;
-
- uint32 i = 4;
-
- ::Graphics::Surface picture; // We make a Surface object for the picture itself.
-
- picture.create(pictureWidth, pictureHeight, ::Graphics::PixelFormat::createFormatCLUT8());
-
- // Produce the picture.
- for (byte y = 0; y < pictureHeight; y++)
- for (int8 plane = 3; plane >= 0; plane--) // The planes are in the opposite way.
- for (uint16 x = 0; x < pictureWidth; x += 8) {
- byte pixel = source[i++];
- for (byte bit = 0; bit < 8; bit++) {
- byte pixelBit = (pixel >> bit) & 1;
- *(byte *)picture.getBasePtr(x + 7 - bit, y) += (pixelBit << plane);
- }
- }
-
- // Copy the picture to a given place on the screen.
- for (uint16 y = 0; y < picture.h; y++)
- for (uint16 x = 0; x < picture.w; x++)
- *getPixel(x + destX, y + destY) = *(byte *)picture.getBasePtr(x, y);
-
- picture.free();
-}
-
void Graphics::refreshScreen() {
// These cycles are for doubling the screen height.
::Graphics::Surface picture;
diff --git a/engines/avalanche/graphics.h b/engines/avalanche/graphics.h
index 0cee2feb8f..67e9c5f030 100644
--- a/engines/avalanche/graphics.h
+++ b/engines/avalanche/graphics.h
@@ -86,8 +86,6 @@ public:
void drawPicture(const ::Graphics::Surface &picture, uint16 destX, uint16 destY); // Can't call .free() here. See Lucerna::showscore() for example.
- void drawPicture_old(const byte *source, uint16 destX, uint16 destY);
-
void refreshScreen();
private: