I have a little problem.
I have a sound with 2 loops and i can easily switch to the second loop, but when i change to the first loop the sounds stops(i thought it was because the end point is behind the current position).
To avoid this problem i tried to set the begin of the loop to the beginning of the first loop and the end of the loop point to the end of the current loop. When the current position of the channel is behind the end of the current loop, the end is set to the end of the first loop.
The code to this idea looks like this:
[code:shepqvn7]//index is the new loop that begins with 0 ms and ends with 1000 ms
//curLoop is the current playing loop that begins with 1000 ms and ends with 2000 ms;
// lps is map with a with all loaded LoopPoints
unsigned int tmp;
unsigned int tmp; channel->getPosition(&tmp,FMOD_TIMEUNIT_MS); pos=tmp;
Unfortunately it didn’t work and the sound stops when I change to the first loop :(.
Has someone an idea how to solve this problem?
- Sep asked 12 years ago
Please login first to submit.