aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scumm/gfx.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/scumm/gfx.cpp b/scumm/gfx.cpp
index 8225b8f6b8..396df69906 100644
--- a/scumm/gfx.cpp
+++ b/scumm/gfx.cpp
@@ -1165,7 +1165,11 @@ void Gdi::drawBitmap(const byte *ptr, VirtScreen *vs, int x, int y, const int wi
if (_vm->_version == 1) {
mask_ptr = _vm->getResourceAddress(rtBuffer, 9) + y * _numStrips + x + _imgBufOffs[1];
-// drawStripC64Mask(mask_ptr, stripnr, height);
+ if (_C64ObjectMode) {
+ // FIXME/TODO: V1 object masks are stored separately
+ } else {
+ //drawStripC64Mask(mask_ptr, stripnr, height);
+ }
} else if (_vm->_version == 2) {
// Do nothing here for V2 games - zplane was handled already.
} else if (flag & dbDrawMaskOnAll) {
@@ -1372,6 +1376,10 @@ void Gdi::drawStripC64Object(byte *dst, int stripnr, int width, int height) {
void Gdi::drawStripC64Mask(byte *dst, int stripnr, int height) {
height >>= 3;
+ // FIXME: this code seems bogus to me. Our masks are *bitmasks*
+ // after all, and this code does treat it like a normal graphics
+ // buffer. In particular, it writes bytes which only have the
+ // lower two bits set... uhh, that can not be correct.
for (int y = 0; y < height; y++) {
for (int i = 0; i < 8; i++) {
byte c = _C64MaskChar[_C64MaskMap[y + stripnr * height] * 8 + i];
@@ -1379,7 +1387,7 @@ void Gdi::drawStripC64Mask(byte *dst, int stripnr, int height) {
dst[2] = dst[3] = (c >> 4) & 3;
dst[4] = dst[5] = (c >> 2) & 3;
dst[6] = dst[7] = (c >> 0) & 3;
- dst += _vm->_screenWidth;
+ dst += _vm->_screenWidth; // FIXME: this probably should be _numStrips, once the rest of drawStripC64Mask is fixed
}
}
}