Still no LoadMusic() command?

Blitz3D Forums/Blitz3D Programming/Still no LoadMusic() command?

Russell(Posted 2006) [#1]
I've been away from B+ and B3D for a while (working with BMax) and was hoping that the music system (powered by FMod) would finally work like the other Load...() commands.

I hope Mark does intend to continue adding to/improving B3D, even though BMax seems to be his baby currently.

I'd REALLY like to see a process along the lines of the other Load..() commands:
song = LoadMusic("MySong.xm")
PlayMusic(song)

etc.

I know FMod allows this, so I have always wondered why it wasn't done this way in the first place.

Russell


DroolBucket(Posted 2006) [#2]
I agree, i dont see why blitz would not implement a loadmusic command. What i really dont like is when one uses playmusic and the music has to re-load. It gives my program a little "hic-up" which is not fixed with loop sound very easy


Picklesworth(Posted 2006) [#3]
From the docs:
You can't 'preload' the audio like you can a sound sample via the LoadSound command. Every time you call the PlayMusic command, the file is reloaded and played. This means that if you use the command while some graphics are moving on-screen, you may get a slight pause when the hard drive seeks and grabs the music file. To avoid this, you might want to use the PlaySound/LoopSound commands instead.


We don't need to make PlayMusic functions look the same way as the Play/Load Sound functions, because they already are the same!


Matty(Posted 2006) [#4]
Don't know how important it is but I don't think midi files can be played with loadsound/playsound only with playmusic.


_PJ_(Posted 2006) [#5]
Yeah I think Matty's right. Also, Cant XM sounds only be used with Load3DSound?


Russell(Posted 2006) [#6]
You can't 'preload' the audio like you can a sound sample via the LoadSound command


Um, Mr. Picklesworth, that proves that they are NOT the same: The LoadSound command allows you to 'preload' a sound (as per your quote from the docs), whereas the PlayMusic command does not.

So what was your point exactly? If they work differently, how can they "already be the same"?

Load "hiccups" make a game look unprofessional, IMHO, since any graphics being drawn can also be affected - jerky motion.

There are really only two things I don't like about Blitz3D, and this is one of them. The other is the unnecessarily large sizes of created exe's, even when the source is quite small: There's no automatic removal of services/functions that are not utilized?

Overall, though, Blitz3D is the bomb. :)

Russell


Picklesworth(Posted 2006) [#7]
Um, Mr. Picklesworth, that proves that they are NOT the same: The LoadSound command allows you to 'preload' a sound (as per your quote from the docs), whereas the PlayMusic command does not.

So what was your point exactly? If they work differently, how can they "already be the same"?


They are already the same in that they play audio.
They are the solution to the above problem because the audio has to be preloaded.
I was comparing the commands to the proposed Load/Play Music.


Russell(Posted 2006) [#8]
Well, duh! ;)

As far as the way they do it, they are not the same. A snow ski and a car both move you along the ground, but they are not the same, are they? ;)

My point is/was that they should work the same way. Blitz is remarkably consistant with the way its commands work, and this one sticks out like a turd in a punch bowl... It would be nice to be given the option of whether we want to load it each time from disk or from memory (as FMod itself allows). Perhaps there's a way to load it into a bank, and then fool Blitz (and/or the OS) that the bank is a storage device and 'load' it from there? There probably is a way, but it'd be much nicer if it was already built-in (an IncludeBin directive would be even nicer still!).

Russell


Picklesworth(Posted 2006) [#9]
What are you solving your problem with for now?


Russell(Posted 2006) [#10]
Not too many choices ATM...I have to put up with the 'hiccup' until this is solved, or possibly just use Ogg/Mp3 files instead. Mark has been really good at updating, but it looks like B3D is not getting new features recently, just bug fixes (which is important, of course). BMax is his new baby, and I do like it, but it has NO built-in FMod at all :(

Once the 3D module is ready for BMax, I wonder what will happen to B3D since BMax + MaxGUI/Max3D will pretty much "do it all" (except mod playing...)?

Russell


DroolBucket(Posted 2006) [#11]
hmmm max 3d?... well i must say i would really hate having to learn the language all over again, especially since i was to lazy to learn bmax in the first place.


John Blackledge(Posted 2006) [#12]
Agreed - can't say this often enough: the major user base is B3D. BRL should be putting all efforts into supporting this.