View Full Version : MP3 Playing in OpenAL
pisces
03-23-2004, 04:57 AM
Hiya all,
I need help once again :S
I read in the openAL guide and saw only wav files can be loaded... is there any way to load in mp3's as well...
I know FMOD does it... but havent really looked at it that much...
Thanks
anubis
03-23-2004, 10:14 AM
take my advice and use ogg. there even is a complete tutorial on how to do that.
http://www.devmaster.net/articles/openal-t...als/lesson8.php (http://www.devmaster.net/articles/openal-tutorials/lesson8.php)
SpreeTree
03-23-2004, 10:28 AM
Mp3's are not supported directly by OpenAL, but they can be read in, as can all music files. You would have to know about the file format, compression methods, and then convert all this into a sound buffer format that OpenAL could use.
Why do you want to use mp3's? Theres a whole bunch of legal crap associated with mp3's, so if its for the file size aspect, then go with what anubis said and use ogg files. Ogg files are supported directly in OpenAL (currently in the Linux version, and soon to be in the win32 version. Dont know about the mac version etc.), and have just as good data compression and lossy-ness(!) as mp3's.
I can't think of why else someone would want to use mp3's, and yeah theres a raft of tutorials out there on ogg vorbis (2 on here, the ogg vorbis sdk docs). Google it...:)
Spree
pisces
03-23-2004, 11:20 AM
Hiya...
thanks. There's no reason about the mp3s... just curiosity. I'm having a look for the Ogg thingy. Thanks again
Pisces
vBulletin, Copyright ©2000-2009, Jelsoft Enterprises Ltd.