aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTravis Howell2004-10-08 10:49:30 +0000
committerTravis Howell2004-10-08 10:49:30 +0000
commitad23981a4e7ab004b6b671ea4a54fb7cc496f247 (patch)
tree5bd2f1f2d00c04d3df733302ef4d795509acc488
parent251a44ea9bbc32744459b8b774ffc83a41c54d7d (diff)
downloadscummvm-rg350-ad23981a4e7ab004b6b671ea4a54fb7cc496f247.tar.gz
scummvm-rg350-ad23981a4e7ab004b6b671ea4a54fb7cc496f247.tar.bz2
scummvm-rg350-ad23981a4e7ab004b6b671ea4a54fb7cc496f247.zip
Cleanup
svn-id: r15469
-rw-r--r--scumm/gfx.cpp22
1 files changed, 16 insertions, 6 deletions
diff --git a/scumm/gfx.cpp b/scumm/gfx.cpp
index ca4b6093f0..40c12480ca 100644
--- a/scumm/gfx.cpp
+++ b/scumm/gfx.cpp
@@ -1375,14 +1375,24 @@ void Gdi::drawBMAPBg(const byte *ptr, VirtScreen *vs, int startstrip) {
// The following few lines more or less duplicate decompressBitmap(), only
// for an area spanning multiple strips. In particular, the codecs 13 & 14
// in decompressBitmap call drawStripHE()
- if (code == 150) {
- fill((byte *)vs->backBuf, vs->pitch, *bmap_ptr, vs->w, vs->h);
- } else if ((code >= 134 && code <= 138) || (code >= 144 && code <= 148)) {
- _decomp_shr = code % 10;
- _decomp_mask = 0xFF >> (8 - _decomp_shr);
-
+ _decomp_shr = code % 10;
+ _decomp_mask = 0xFF >> (8 - _decomp_shr);
+ code /= 10;
+
+ switch (code) {
+ case 13:
+ drawStripHE((byte *)vs->backBuf, vs->pitch, bmap_ptr, vs->w, vs->h, false);
+ break;
+ case 14:
drawStripHE((byte *)vs->backBuf, vs->pitch, bmap_ptr, vs->w, vs->h, true);
+ break;
+ case 15:
+ fill((byte *)vs->backBuf, vs->pitch, *bmap_ptr, vs->w, vs->h);
+ break;
+ default:
+ error("Gdi::drawBMAPBg: default case %d", code);
}
+
copyVirtScreenBuffers(Common::Rect(vs->w, vs->h));
int numzbuf = getZPlanes(ptr, zplane_list, true);