[Scummvm-devel] compressing Dragon History dubbing into MP3/OGG/whatever

Robert Špalek rspalek at gmail.com
Mon Jun 7 06:45:32 CEST 2010


hi guys,

I've been thinking that now that the Dragon History code is stable and plays
well the original game files, the time has come to add support for decoding
compressed dubbing, so that one can decrease the length of the game archives
that need to be downloaded.  the game uses 8-bit mono uncompressed audio
recorded in 22 kHz, and it takes 144 MB uncompressed, 66 MB as a ZIP file,
and 46 MB as a RAR file.  compressed in a lossy audio format, one could
hopefully achieve 1/8 of that.

I already have a trivial C-program that reads that dubbing archive and
produces a few thousand of raw audio files.  it won't be too hard to write a
shell script that iterates through all of them and runs a codec on each of
them.  I could possibly even use one of the ScummVM tools to do this
recoding (which one?).

I have a few questions targeted at minimizing the time I'd have to spend
experimenting with things to achieve an acceptable outcome.  I hope some of
you is experienced in this area.

1. what is the best known codec and its settings for audio with the
parameters above?  I'm not sure whether MP3 or OGG is better in this range,
what's the desired bit-rate, and which one format is generally preferred
(considering the cpu needed to decode it).

2. is there a nice library in ScummVM implementing reading an archive of
compressed sound files?  ideally this library would be general enough so
that one can store anything in it in any format, and the game engine doesn't
need to bother about it.  in that case it would be easy in the future to
recode the files to a higher bit-rate or change the codec without
recompilation of the game player.  the sound archive format used in Dragon
History is absolutely idiotic and must not be used for anything but reading
the original sound archives for compatibility reasons, and I also don't
wanna reinvent the wheel.

I'd like to modify the game engine such that it would accept whichever
dubbing is available.

by the way, I have been contacted by someone from Internet who sent me about
80%-corrected English scripts.  soon we will hopefully be able to announce a
new version that the original authors don't need to be ashamed about ;-)
 I've just started thinking that if I make a new package, why don't I merge
this change with the recode of the dubbing so that the complete game archive
would fit into, say, 20 MB or whatever appropriate.  if you are interested
in looking at the corrected scripts, they are already uploaded on the
web-page of the game (only the source scripts and not the compiled game,
because the latter will only be updated after proofreading has been done).

http://www.ucw.cz/draci-historie/src/game-scripts/en/
http://www.ucw.cz/draci-historie/source/new-sources-2.zip

kind regards!
-- 
Robert Špalek <rspalek at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.scummvm.org/pipermail/scummvm-devel/attachments/20100606/27d69a67/attachment.html>


More information about the Scummvm-devel mailing list