aboutsummaryrefslogtreecommitdiff
path: root/engines/parallaction/graphics.cpp
diff options
context:
space:
mode:
authorNicola Mettifogo2008-01-28 18:15:06 +0000
committerNicola Mettifogo2008-01-28 18:15:06 +0000
commitb80419efb4177fb3cd5d8e2ace3d08d5840fdcc0 (patch)
treecf1244c5b8f1ae11ecadeec905f2109fe72a364a /engines/parallaction/graphics.cpp
parentefdc6f646f4b051d956d6c373da0b29ee3514694 (diff)
downloadscummvm-rg350-b80419efb4177fb3cd5d8e2ace3d08d5840fdcc0.tar.gz
scummvm-rg350-b80419efb4177fb3cd5d8e2ace3d08d5840fdcc0.tar.bz2
scummvm-rg350-b80419efb4177fb3cd5d8e2ace3d08d5840fdcc0.zip
Made halfbrite work again.
svn-id: r30685
Diffstat (limited to 'engines/parallaction/graphics.cpp')
-rw-r--r--engines/parallaction/graphics.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/engines/parallaction/graphics.cpp b/engines/parallaction/graphics.cpp
index 6479a796d2..eba8dfff39 100644
--- a/engines/parallaction/graphics.cpp
+++ b/engines/parallaction/graphics.cpp
@@ -345,10 +345,18 @@ void Gfx::drawBalloons() {
}
void Gfx::updateScreen() {
-#if 0
+
+ g_system->copyRectToScreen((const byte*)_buffers[kBit2]->pixels, _buffers[kBit2]->pitch, _screenX, _screenY, _vm->_screenWidth, _vm->_screenHeight);
+
+ Graphics::Surface *surf = g_system->lockScreen();
+ drawGfxObjects(*surf);
+ g_system->unlockScreen();
+
if (_halfbrite) {
+ // FIXME: the implementation of halfbrite is now largely sub-optimal in that a full screen
+ // rewrite is needed to apply the effect.
Graphics::Surface *surf = g_system->lockScreen();
- byte *src = (byte*)_buffers[kBitFront]->pixels;
+ byte *src = (byte*)_buffers[kBit2]->pixels;
byte *dst = (byte*)surf->pixels;
for (int i = 0; i < surf->w*surf->h; i++) {
*dst++ = *src++ | 0x20;
@@ -357,15 +365,7 @@ void Gfx::updateScreen() {
drawCircle(_hbCirclePos.x, _hbCirclePos.y, _hbCircleRadius, 0, &halfbritePixel, surf->pixels);
}
g_system->unlockScreen();
- } else {
- g_system->copyRectToScreen((const byte*)_buffers[kBitFront]->pixels, _buffers[kBitFront]->pitch, _screenX, _screenY, _vm->_screenWidth, _vm->_screenHeight);
}
-#endif
- g_system->copyRectToScreen((const byte*)_buffers[kBit2]->pixels, _buffers[kBit2]->pitch, _screenX, _screenY, _vm->_screenWidth, _vm->_screenHeight);
-
- Graphics::Surface *surf = g_system->lockScreen();
- drawGfxObjects(*surf);
- g_system->unlockScreen();
drawInventory();