Loading Audio into a Bank

Blitz3D Forums/Blitz3D Programming/Loading Audio into a Bank

ClayPigeon(Posted 2012) [#1]
Is there any way that I could load audio data from a file into a bank or other storage medium in Blitz? I need access to the audio data in order to do some kind of analyzing. I DO NOT need to be able to play the audio directly from the bank, just get the audio. I think this might involve winmm or mci or whatever it is. I think it is capable of a lot of different formats, which is useful. Any ideas?


Rroff(Posted 2012) [#2]
You could use the built in file commands to move the data byte by byte into a bank but that would be a bit slow. Probably a windows API command that can do it quicker (not sure if the RTL function can).


Bobysait(Posted 2012) [#3]
Just use "ReadBytes" command to push datas from your file (previously loaded with "ReadFile") to your bank
You'll need to parse the header of your audio file.


ClayPigeon(Posted 2012) [#4]
I know how I would get the data; my point is, to DECODE the information, e.g. if I'm using a special codec like .ogg or something.