private void output_Started(object sender, PlayFrameEventArgs e) { invoke(() => { btnMic1.Enabled = btnMic2.Enabled = false; btnSource1.Enabled = btnSource2.Enabled = false; }); }
private void OnFramePlayingStarted(PlayFrameEventArgs e) { isPlaying = true; if (FramePlayingStarted != null) { FramePlayingStarted(this, e); } }
private void output_FramePlayingStarted(object sender, PlayFrameEventArgs e) { updateTrackbar(e.FrameIndex); if (e.FrameIndex + e.Count < decoder.Frames) { int previous = decoder.Position; decoder.Seek(e.FrameIndex); Signal s = decoder.Decode(e.Count); decoder.Seek(previous); updateWaveform(s.ToFloat(), s.Length); } }
private void AudioOutputDeviceFramePlayingStarted(object sender, PlayFrameEventArgs e) { //MemoryStream playStream = new MemoryStream(); //memoryStream.CopyTo(playStream); //MemoryStream stream = GetRepairedStream(memoryStream); //stream.Seek(0, SeekOrigin.Begin); //decoder = new WaveDecoder(stream); //decoder.Decode(e.Count); //if (e.FrameIndex + e.Count < decoder.Frames) //{ // int previous = decoder.Position; // decoder.Seek(e.FrameIndex); // Signal s = decoder.Decode(e.Count); // decoder.Seek(previous); //} }