This project has moved. For the latest updates, please go here.

How to stop a audio file from playing in FireAndForgetAudioSample?

Aug 31, 2016 at 1:55 AM
I currently use the following to play a sound file:
FireAndForgetAudioSample.AudioPlaybackEngine.Instance.PlaySound("Sounds/sound.mp3");
This file is very long and I want to stop playing the file mid-way. How do I accomplish this?

Furthermore, Can I play other sound files after the "sound.mp3" file has been stopped?

Assistance is appreciated.
Coordinator
Aug 31, 2016 at 8:31 AM
Well the whole point of fire and forget is that you "forget" about the file once you've started playing it. If you want to remember it, and control it, then create your own MixingSampleProvider and add and remove inputs as needed.

And yes, you can play other files after one has stopped, so long as your mixer is set up to always produce sound (i.e. silence) even when no inputs are connected