SCUMM/Technical Reference/Sound resources

From ScummVM :: Wiki
< SCUMM‎ | Technical Reference
Revision as of 02:00, 5 March 2009 by Jestar jokin (talk | contribs) (→‎Compressed: removed plural for clarity)
Jump to navigation Jump to search

Music

  • Adlib, GM, MT-32 etc formats
  • Digital
  • iMUSE (separate tracks and specific markers in each song format)

Sounds

Resource.001

Up until the CD Talkie version of Indiana Jones and the Fate of Atlantis (Indy 4), sounds are stored in the .001 resource files. They are contained within ROOM(?) blocks.

"SOUN" header (incl. size?)
"SBL " header
"CREA" block (Creative VOC file)

Games that use CD tracks (Loom/CD, MI1/CD, Zak256/FM-TOWNS) are a bit different. For MI1/CD at least, the block size is 32-bytes, and provides information on the CD track to play.

MONSTER.SOU

Original

From Indy 4 onwards, sound effects and speech are stored in a separate resource file called "MONSTER.SOU". The format is:

"SOU " header (incl. size?)
one or more {
 "VCTL" header/block (contains lip-synch tags?)
 "CREA" block (Creative VOC file)
}

Compressed

ScummVM can use compressed monster.sou files created with the tool "compress_scumm_sou.exe". Aside from using either MP3, OGG, or FLAC formats for the sound data, they contain a mapping table followed by the sound data, like so:

size_of_table  : uint32
size_of_table / 16 times {
 orig_offset   : uint32
 actual_offset : uint32
 num_tags      : uint32
 sound_size    : unit32
}
size_of_table / 16 times {
 num_tags times {
  tag          : uint8
 }
 sound         : sound_size (sound file - MP3/OGG/FLAC)
} 

Each entry in the table has 4 items, each item is 4 bytes, so a table with one entry has a size of 16.

The original offset is what the game will try to play, the actual offset is taken from after the index table.

Each sound is directly preceded by its lip-synch tags.