[Scummvm-devel] MP3 Support incomplete?

Lionel Ulmer lionel.ulmer at free.fr
Mon Apr 15 02:13:11 CEST 2002


> I tried compiling the mp3-compressed MONSTER.SOU support today (using the
> latest CVS) because it seemed like a really cool feature, but I ran into a
> problem. After changing a few things in the source to get it to compile
> properly, it seems that a function (Scumm::playSfxSound_MP3(void *sound,
> uint32 size)) hasn't been implemented yet.

Well, as the ScummVM code was moved quite a lot recently (new classes, new
files, ...), there is no wonder that things got broken :-)

And as Ludde (who did the last mixer work) seems not to compile in MP3
support, he did not see that the code was broken. I will try to fix it
tonight (if nobody beats me to it).

> Oh, also, in the tools/readme.txt file, it gives incorrect instructions
> for compiling the MP3 support. It says to define USE_COMPRESSED_SOUND to
> enable it, when the define is actually COMPRESSED_SOUND_FILE. Personally,
> the first define is better since it fits with the USE_[some feature] scheme
> that the rest of the program uses.

Well, I am responsible for this code... Maybe my choice of name was badly
chosen. But anyway, always trust the source and not the readme :-))

Anyway, we REALLY need a new building method (as there are a lot of defines
that can be changed according to the system, the availability of drivers,
...).

> And lastly -- this isn't really that important, I was just curious -- the
> tools/extract program that compresses the MONSTER.SOU file into a
> MONSETER.SO3/IDX is upsampling the audio (in Indy4) from 11111 hz to 22100
> hz. I'm not exactly sure if this was done on purpose, or if it's a mistake.

I did it on purpose.

> Is it done because libmad doesn't support MPEG-2.5 Layer III audio, which is
> what would be necessary to playback a 11.025khz file? Does the ScummVM sound
> mixer only mix at frequency? Just wondering. :)

The reason is really simple : the MP3 mixer in ScummVM only mixes at one
given frequency and as most of Day of the Tentacle sounds are in 22.050 kHz,
I choose this frequency as the default one for all MP3s. I agree that we
loose some space in the sounds that are compressed at 11.025 or even at 8000
but well, the mixer is sooo much easier to read than the multi-frequency one
for standard .SOU files.

Hmmm, this all reminds me that I need to make a new, cleaner version of the
MP3 compression tool :-)

-- 
		 Lionel Ulmer - http://www.bbrox.org/




More information about the Scummvm-devel mailing list