I want to play short sounds (like beeps).
But I want to play them several times, one after the other, but without repeating them and I may modify some properties of these beeps, so I need to use the channel pointer.
How can I know if the sound is not finished ? Because if I try to modify this short sound when the sound is finished, I got an "invalid handle" message.
Do I have to register an end callback ?
Because the sound is so short (less than 1 sec) that it seems to me to be a lot of work for FMOD to register an new end callback each time I start a new beep ?
Is there another way to achieve what I want to ?
- Ceydric asked 7 years ago
But what if the sound is already playing ?
I don’t want the sound to start a second time before the first one is finished.
For now I’m testing the channel by asking if the channel is playing with the "isPlaying" function first.
If it returns "invalid handle", I know the sound is finished and I may be able to start it again.
If the handle is correct, I can continue modifying the properties I want.
I just hope this is the best solution and that getting an "invalid handle" is not too much time consuming (very fast realtime is important to me).
- Ceydric answered 7 years ago
Please login first to submit.