private void ResetLocalState() { strStopReq = StopRequest.Immediately; IsStreamed = false; streamProvider = null; IsStopped = false; }
private void ResetLocalState() { lock (this.strLock) { this.strStopReq = StopRequest.Immediately; this.isStreamed = false; this.streamProvider = null; this.ReleaseStreamBuffers(); } }
public void Initialize(int outputCount, IAudioStreamProvider provider) { _channelsCount = outputCount; _streamProvider = provider; _channels = new AudioChannel[_channelsCount]; for (int i = 0; i < _channelsCount; ++i) { _channels[i] = new AudioChannel(); } }
void INativeAudioSource.Play(IAudioStreamProvider streamingProvider) { lock (this.strLock) { if (!this.isInitial) throw new InvalidOperationException("Native audio source already in use. To re-use an audio source, reset it first."); this.isInitial = false; this.isStreamed = true; this.strStopReq = StopRequest.None; this.streamProvider = streamingProvider; AudioBackend.ActiveInstance.EnqueueForStreaming(this); } }
void INativeAudioSource.Play(IAudioStreamProvider streamingProvider) { lock (this.strLock) { if (!this.isInitial) { throw new InvalidOperationException("Native audio source already in use. To re-use an audio source, reset it first."); } this.isInitial = false; this.isStreamed = true; this.strStopReq = StopRequest.None; this.streamProvider = streamingProvider; AudioBackend.ActiveInstance.EnqueueForStreaming(this); } }
private void ResetLocalState() { lock (this.strLock) { this.strStopReq = StopRequest.Immediately; this.isStreamed = false; this.streamProvider = null; this.ReleaseStreamBuffers(); } }
void INativeAudioSource.Play(IAudioStreamProvider streamingProvider) { this.initial = false; }
void INativeAudioSource.Play(IAudioStreamProvider streamingProvider) { this.initial = false; }
public void Initialize(int blockSize, IAudioStreamProvider provider) { Samples = new double[blockSize]; _streamProvider = provider; }