aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authoruruk2013-07-13 18:21:18 +0200
committeruruk2013-07-13 18:21:18 +0200
commit58dc18a2da981273fd0fb10ba53274a14fec88e6 (patch)
tree947fed971a22f74c68094e227355b628b0ab89d4 /engines
parent0f8a091597092f7efc308f4d20a3d09c648fcb2a (diff)
downloadscummvm-rg350-58dc18a2da981273fd0fb10ba53274a14fec88e6.tar.gz
scummvm-rg350-58dc18a2da981273fd0fb10ba53274a14fec88e6.tar.bz2
scummvm-rg350-58dc18a2da981273fd0fb10ba53274a14fec88e6.zip
AVALANCHE: Move the height-doubling part from Lucerna to Graph.
Diffstat (limited to 'engines')
-rw-r--r--engines/avalanche/graph.cpp6
-rw-r--r--engines/avalanche/lucerna2.cpp6
2 files changed, 7 insertions, 5 deletions
diff --git a/engines/avalanche/graph.cpp b/engines/avalanche/graph.cpp
index d932d12be8..e101749027 100644
--- a/engines/avalanche/graph.cpp
+++ b/engines/avalanche/graph.cpp
@@ -79,7 +79,11 @@ void Graph::drawBar(int16 x1, int16 y1, int16 x2, int16 y2, int16 color) {
}
void Graph::copySurface(Graphics::Surface source) {
- _surface.copyFrom(source);
+ for (uint16 y = 0; y < _screenHeight / 2; y++)
+ for (uint16 x = 0; x < _screenWidth; x ++) {
+ for (byte j = 0; j < 2; j++) // We copy every line twice to reach 400 picture height.
+ *(byte *)_surface.getBasePtr(x, y * 2 + j) = *(byte *)source.getBasePtr(x, y);
+ }
}
void Graph::refreshScreen() {
diff --git a/engines/avalanche/lucerna2.cpp b/engines/avalanche/lucerna2.cpp
index 493d114b39..e878e7760c 100644
--- a/engines/avalanche/lucerna2.cpp
+++ b/engines/avalanche/lucerna2.cpp
@@ -251,8 +251,8 @@ void Lucerna::load(byte n) { /* Load2, actually */
byte pixel = f.readByte();
for (byte i = 0; i < 8; i++) {
byte pixelBit = (pixel >> i) & 1;
- for (byte j = 0; j < 2; j++) // We draw every line twice to reach 400 picture height.
- *(byte *)background.getBasePtr(x + 7 - i, y * 2 + j) += (pixelBit << plane);
+ //for (byte j = 0; j < 2; j++) // We draw every line twice to reach 400 picture height.
+ *(byte *)background.getBasePtr(x + 7 - i, y /** 2 + j*/) += (pixelBit << plane);
}
}
@@ -260,8 +260,6 @@ void Lucerna::load(byte n) { /* Load2, actually */
background.free();
- _vm->_graph.refreshScreen();
-