public void Load(int sampleOffset) { playing = false; StreamSourceVoice = new StreamSourceVoice(system.AudioDevice); StreamSourceVoice.SetupBuffer(this, false, sampleOffset); // no looping by default, we can change this later StreamSourceVoice.StreamStoppedAnyReason += (o, e) => { playing = false; }; }
public void Dispose() { StreamSourceVoice.Dispose(); StreamSourceVoice = null; }
public DummySourceVoiceSlot(StreamSourceVoice streamSourceVoice) { CurrentSourceVoice = streamSourceVoice; }