TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
sawass sawass
NA
36
23.7k
Stop brodcastig in 3 external soundcard
Jun 6 2011 6:08 PM
Hello
,
I
want to stop
the
broadcasting
of a
sound
wave
in
looping.I
've
used
this method but
to no avail
:
private void btnStop_Click(object sender, EventArgs e)
{
if (output != null)
{
if (output.PlaybackState == NAudio.Wave.PlaybackState.Playing)
{
output.Stop();
}
}
}
I use
the
play
function
follows:
public void PlaySoundInDevice(int deviceNumber, string fileName)
{
if (outputDevices.ContainsKey(deviceNumber))
{
outputDevices[deviceNumber].WaveOut.Dispose();
outputDevices[deviceNumber].WaveStream.Dispose();
}
var waveOut = new WaveOut();
waveOut.DeviceNumber = deviceNumber;
WaveStream waveReader = new WaveFileReader(fileName);
LoopStream loop = new LoopStream(waveReader);
waveOut = new WaveOut();
waveOut.Init(loop);
waveOut.Play();
// hold onto the WaveOut and WaveStream so we can dispose them later
outputDevices[deviceNumber] = new PlaybackSession { WaveOut = waveOut, WaveStream = waveReader };}
Ihave 3 external soundcard and the wave out of the 3 sond card
Is
anybody
can
help me
please
and
thank you
in advance
.
Reply
Answers (
0
)
Please Help - RowStyle Event
Add a new user using csharp