aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/console.cpp
diff options
context:
space:
mode:
authorColin Snover2016-12-17 18:50:23 -0600
committerColin Snover2016-12-17 18:55:22 -0600
commit07919b79baca911dcda4708406f5dee85d22b655 (patch)
treec3c84f3fa32a6d597630ad77a637a1de1291fd5c /engines/sci/console.cpp
parent7e9ae90abd094fc836e7d9c9497eaa6ec138b7b0 (diff)
downloadscummvm-rg350-07919b79baca911dcda4708406f5dee85d22b655.tar.gz
scummvm-rg350-07919b79baca911dcda4708406f5dee85d22b655.tar.bz2
scummvm-rg350-07919b79baca911dcda4708406f5dee85d22b655.zip
SCI32: Improve SciBitmap segment table debugging output
Diffstat (limited to 'engines/sci/console.cpp')
-rw-r--r--engines/sci/console.cpp20
1 files changed, 11 insertions, 9 deletions
diff --git a/engines/sci/console.cpp b/engines/sci/console.cpp
index cfbc2f3a34..63a1f0c2ec 100644
--- a/engines/sci/console.cpp
+++ b/engines/sci/console.cpp
@@ -2216,9 +2216,17 @@ bool Console::segmentInfo(int nr) {
case SEG_TYPE_ARRAY:
debugPrintf("SCI32 arrays\n");
break;
- case SEG_TYPE_BITMAP:
- debugPrintf("SCI32 bitmaps\n");
+
+ case SEG_TYPE_BITMAP: {
+ BitmapTable &table = *(BitmapTable *)mobj;
+ debugPrintf("SCI32 bitmaps (total %d)\n", table.entries_used);
+ for (uint i = 0; i < table.size(); ++i) {
+ if (table.isValidEntry(i)) {
+ debugPrintf(" [%04x] %s", i, table[i].toString().c_str());
+ }
+ }
break;
+ }
#endif
default :
@@ -4663,13 +4671,7 @@ void Console::printBitmap(reg_t reg) {
const SciBitmap &bitmap = table->at(reg.getOffset());
- debugPrintf("SCI32 bitmap (%dx%d; res %dx%d; origin %dx%d; skip color %u; %s; %s):\n",
- bitmap.getWidth(), bitmap.getHeight(),
- bitmap.getXResolution(), bitmap.getYResolution(),
- bitmap.getOrigin().x, bitmap.getOrigin().y,
- bitmap.getSkipColor(),
- bitmap.getRemap() ? "remap" : "no remap",
- bitmap.getShouldGC() ? "GC" : "no GC");
+ debugPrintf("SCI32 bitmap (%s):\n", bitmap.toString().c_str());
Common::hexdump((const byte *) bitmap.getRawData(), bitmap.getRawSize(), 16, 0);
}