Quantcast
Channel: naudio Work Item Rss Feed
Viewing all articles
Browse latest Browse all 738

Commented Unassigned: WaveOut.Stop() pauses playback instead of stopping [16455]

$
0
0
Normally you'd expect Stop() to stop playback and seek to the beginning, but it doesn't.
In the following code:
```
_myWaveOut = new DirectSoundOut(device);
_myAudioFileReader = new AudioFileReader(path);
_myWaveOut.Init(_myAudioFileReader);
_myWaveOut.Play();
// ...
_myWaveOut.Stop();
_myWaveOut.Play();
// ...
```
After Play() is called for the second time, the file starts playing from the position it was at when Stop() was called. Please change this so it starts playing from the start like it should.
Comments: waveOut.Stop simply stops your device from playing audio. It has no idea what it is playing. It might not be an audio file - it might be synthesized music, or streamed audio over a network. So it is not possible for it to "seek to the beginning".

Viewing all articles
Browse latest Browse all 738

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>