/// <summary> /// Start recording /// </summary> public void StartRecording() { OpenWaveInDevice(); if (recording) { throw new InvalidOperationException("Already recording"); } MmException.Try(WaveInterop.waveInStart(waveInHandle), "waveInStart"); recording = true; }
/// <summary> /// Start recording /// </summary> public void StartRecording() { if (recording) { throw new InvalidOperationException("Already recording"); } length = 0; position = 0; MmException.Try(WaveInterop.waveInStart(waveInHandle), "waveInStart"); recording = true; }
/// <summary> /// Start recording /// </summary> public void StartRecording() { if (recording) { throw new InvalidOperationException("Already recording"); } OpenWaveInDevice(); MmException.Try(WaveInterop.waveInStart(waveInHandle), "waveInStart"); recording = true; ThreadPool.QueueUserWorkItem((state) => RecordThread(), null); }
/// <summary> /// Start recording /// </summary> public void StartRecording() { if (captureState != CaptureState.Stopped) { throw new InvalidOperationException("Already recording"); } OpenWaveInDevice(); MmException.Try(WaveInterop.waveInStart(waveInHandle), "waveInStart"); captureState = CaptureState.Starting; ThreadPool.QueueUserWorkItem((state) => RecordThread(), null); }
public void StartRecording() { if (this.recording) { throw new InvalidOperationException("Already recording"); } this.OpenWaveInDevice(); this.EnqueueBuffers(); MmException.Try(WaveInterop.waveInStart(this.waveInHandle), "waveInStart"); this.recording = true; }
public void StartRecording() { if (this.recording) { throw new InvalidOperationException("Already recording"); } this.OpenWaveInDevice(); MmException.Try(WaveInterop.waveInStart(this.waveInHandle), "waveInStart"); this.recording = true; ThreadPool.QueueUserWorkItem(delegate(object state) { this.RecordThread(); }, null); }