i want to know the length of a audio file (.wav) BEFORE i am trying to play it. I need the information and don’t want to introduce all the overhead with creating a sound and then getting the length from that (i guess i need to really create/play it muted and then call on the fmod-sound getlength.. but maybe that is what one needs to do nonetheless, so for that i need to know how costly it is to create/check the sound instead of compiling a list of all sound-lengths in advance)
so what would be the best/fastest way to get the length for them?
thanks a lot for your answers!
- black-l asked 9 years ago
I would prefer this, it’s fast and works for all supported file formats:
system->createStream("filename.wav", FMOD_OPENONLY, 0, &sound);
if it needs to be very very fast then I would check the wav header myself as a1psx recommended
- mylo answered 9 years ago
Please login first to submit.