0
0

I’ve been converting some old code using FMOD 3 to FMOD Ex. The migration was mostly painless, except for one problem that took me days to solve. To make a long story short, this code, which is being called in a channel-end-callback, does not work:

fsys->playSound(FMOD_CHANNEL_REUSE, stream, true, channel);
channel->setPosition(newPosition, FMOD_TIMEUNIT_MS);

This code works perfectly:

fsys->playSound(FMOD_CHANNEL_REUSE, stream, false, channel);
channel->setPosition(newPosition, FMOD_TIMEUNIT_MS);
channel->setPaused(true);

Basically, if playSound has paused = true, any attempt to set the position fails (returns FMOD_OK, but has no effect), the position is permanently set to zero, and no further operations (including playback) work. Everything returns FMOD_OK, but does not actually do anything. If I use playSound with paused = false, and then pause it myself, everything works perfectly fine.

  • You must to post comments
0
0

Thanks for your bug report, we have fixed this up for our next release. There is also a chance that your work around would case an error when releasing the system, this has been fixed as well.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.