Playing music

BlitzMax Forums/BlitzMax Programming/Playing music

GfK(Posted 2007) [#1]
Hello.

After just doling out nigh on £50 on music for my game, its come to light that in Blitzmax there's no way to actually play music other than loading the whole lot into memory like a normal sound?

I wanted to have two tracks playing at once and cross-fade them. It looks like I'm either going to have to drop that idea, or use loads of memory, right?

How's everybody else handling this?


Thareh(Posted 2007) [#2]
Have you had a look at FMOD?
I think FMOD can stream sound files.

Good luck! :)


LarsG(Posted 2007) [#3]
or alternatively BASS or Audiere..


tonyg(Posted 2007) [#4]
or Maxmod ?


Grey Alien(Posted 2007) [#5]
GfK. Yeah there is no ogg streaming in Max :-( Also don't forget to free them up properly with Stop Channel or you'll have an ALMIGHTY memory leak (an early version of my framework had this! It didn't show in Max with that command that shows memory used but it showed in Task Manager).

I believe FMOD can only be used for free projects unless you want to shell out big money on a commercial license.


Grisu(Posted 2007) [#6]
Fmod is allmighty. Though too expensive to go commercial. Well, I would give my life for a decent sound/music support in bmx. :(


GfK(Posted 2007) [#7]
TonyG - Maxmod is perfect!! Thanks!

BRL: In the name of sanity PLEASE add this to Blitzmax as standard!! Its an awesome addition.


REDi(Posted 2007) [#8]
Your checks in the post tonyg ;)

Thanks GfK, glad you like it, biggest problem is its not crossplatform... yet ;)

BTW MP3 support is added in the next release! (and WMA if I can figure out the WAVEFORMATEX for it)


GfK(Posted 2007) [#9]
I'm not bothered about MP3 support since I use OGG anyway. :)

Cross-platform should be top of your 'to do' list ;)


REDi(Posted 2007) [#10]
Yeah, I've put that off for a while because streaming is on Skidracers to do list for FreeAudio, so it'd be better to run it all through that in the end anyway.

I prefer OGG to, but I'm writing a DJ app and MP3 support is a must have really.


GfK(Posted 2007) [#11]
Streaming is vital, imho. I was quite surprised to find that Blitzmax didn't already have it.

I can't justify using 40mb of RAM for a 4-minute track.


REDi(Posted 2007) [#12]
It shouldnt be to hard to add streaming into FreeAudio, So fingers crossed skid'll find some time for it soon.


popcade(Posted 2007) [#13]
REDi, how about submit this to pub.mod/axe.mod, this fills the gap of BMax audio, what we need is a cross platform driver..either freeaudio or portaudio.


REDi(Posted 2007) [#14]
Hi yoko, AFAIK it's up to BRL what ends up in the pub/axe folders, if they wanted it they would ask ;)

I've had it running through portaudio before (thanks to Chris C and Skidracer), but it suffered serious stability problems, probably down to my code rather than portaudio tho :?