public void Dispose() { if (UtilityAudio.PlaybackDevice != null) { UtilityAudio.Dispose(); } }
void MainFormFormClosing(object sender, FormClosingEventArgs e) { if (midiIn != null) { midiIn.Dispose(); midiIn = null; } if (midiOut != null) { midiOut.Dispose(); midiOut = null; } if (vstForm != null) { vstForm.Dispose(); vstForm = null; } UtilityAudio.Dispose(); }