Exemplo n.º 1
0
        private void buttonStopRecording_Click(object sender, EventArgs e)
        {
            if (_asioIn != null)
            {
                if (_plmRec != null)
                {
                    _plmRec.Stop();
                    _plmRec = null;
                }
                // stop the device, since we don't need it anymore
                _asioIn.Stop();
                // and dispose (unjoin and disable any channel)
                _asioIn.Dispose();
                _asioIn = null;

                this.comboBoxAsioInputDevice.Enabled   = true;
                this.comboBoxAsioInputChannel.Enabled  = true;
                this.buttonStartRecording.Enabled      = true;
                this.buttonStopRecording.Enabled       = false;
                this.radioButtonNoFullDuplex.Checked   = true;
                this.radioButtonAsioFullDuplex.Checked = false;
                this.radioButtonBassFullDuplex.Checked = false;
                this.radioButtonNoFullDuplex.Enabled   = false;
                this.radioButtonAsioFullDuplex.Enabled = false;
                this.radioButtonBassFullDuplex.Enabled = false;
                this.comboBoxBassDevice.Enabled        = false;
                this.checkBoxSaveToWave.Enabled        = false;
                this.progressBarRecL.Value             = 0;
                this.progressBarRecR.Value             = 0;
            }
        }
Exemplo n.º 2
0
        private void buttonStop_Click(object sender, System.EventArgs e)
        {
            if (plm != null)
            {
                plm.Notification -= new EventHandler(plm_Notification);
                plm.Stop();
                plm = null;
            }
            this.progressBarLeft.Value  = 0;
            this.progressBarRight.Value = 0;

            if (enc != null)
            {
                enc.Stop();                  // finish encoding
                enc.Dispose();
                enc = null;
            }
            if (asio != null)
            {
                asio.RemoveMirror();
            }

            asio.Stop();
            this.buttonStart.Enabled = true;
        }
Exemplo n.º 3
0
        private void buttonStop_Click(object sender, System.EventArgs e)
        {
            if (_asioOut != null)
            {
                // stop the DSP
                _plmPlay.Stop();
                _plmPlay = null;
                // stop the device, since we don't need it anymore
                _asioOut.Stop();
                // and dispose (unjoin and disable any channel)
                _asioOut.Dispose();
                _asioOut = null;
                // and free the source channel
                Bass.BASS_StreamFree(_stream);
                _stream = 0;

                this.comboBoxAsioOutputDevice.Enabled  = true;
                this.comboBoxAsioOutputChannel.Enabled = true;
                this.buttonOpenFile.Enabled            = true;
                this.buttonStop.Enabled     = false;
                this.progressBarPlayL.Value = 0;
                this.progressBarPlayR.Value = 0;
            }
        }