0
0

I can play an infinite number short of non-looping sounds with no problem (because they clean up properly when the sound is over). However, I’m having trouble with looping sounds.

I use FSOUND_StopSound on a looping channel when I’m done with it. But after a few dozen of these bad things happen… sound fail to open. I have to assume I’m just using the wrong method of cleaning up sounds, so what SHOULD I be doing?

Thanks! :)

  • You must to post comments
0
0

Yes, I’m using FSOUND_FREE to select the channel. It’s a looping sound of a door slidding open. But the door has a chance of shutting during the opening process.

So when the door starts to open I play the looped sound and remember the channel. When the door is closing I decrease it’s volume (so to sound doesn’t abruptly stop). When it’s volume reaches zero I use FSOUND_StopSound on the channel. I ensure that it never starts playing a new looped sound effect until I’ve called FSOUND_StopSound on the original channel.

Openning and closing the door repeatedly causes FSOUND_Sample_Load to eventually fail (for any sound effect).

I’ve also tried FSOUND_SetLoopMode and setting the channel to loop false in hopes that the sound would reach it’s end and clean up by itself… still no luck.

  • You must to post comments
0
0

Oh… oops. I thought FMOD was managing duplicate loading behind the scenes. So do you recommend that I load every sound in the game at start up and manage when those are played?

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.