Request: Music Functions
BlitzMax Forums/BlitzMax Module Tweaks/Request: Music Functions
| ||
I'm not sure if this is a reasonable request, however I hope there're music related function being parts of official package like these. 1.OGG streaming that doesn't required to load into RAM first. 2.XM playing(as Papa is doing it, however not part of official BMax package) So that to enable legacy usage like PlayMusic will be great, just hope it possible. |
| ||
+1 |
| ||
Yep, that'd be nice. |
| ||
++ |
| ||
Music playback is not morally feasible as it stands. You either need threading, or constant PlaySong() polling, which to get accurate needs a fair amount of calls per sec, which is quite ugly and more intensive than it needs to be. Music is very important of course. So threading is the morally correct option. =] But we have to wait for BRL to make their code threadsafe, which might never happen. |
| ||
Hmmm, I've looked through the process from LoadSound and my guess is the decode_ogg and read_ogg functions are taking the time because the parm that is passed is 'size' calculated as the total size with the result being put in memory pointed to by t.samples. Once the decode_ogg has been run is it a case of issuing read_ogg in increments and appending to the memory area? I know you'd have to kick-off the read manually but couldn't it be event driven? Once the TSOUND is created (to whatever degree) Playsound should work and shouldn't overtake the loading. Just an idea hatched in a very short amount of time so blaze away. |
| ||
I'm trying to move over to fmod for the time being. |
| ||
Thanks for letting me know :) Anyway, opened a new topic. |