mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-26 09:48:45 -05:00
Multi device support: removed threaded sample sink add/remove in DSPEngine
This commit is contained in:
parent
2f080bf45b
commit
5de7b0168e
@ -125,18 +125,6 @@ void DSPEngine::removeSink(SampleSink* sink, uint deviceIndex)
|
|||||||
m_deviceEngines[deviceIndex]->removeSink(sink);
|
m_deviceEngines[deviceIndex]->removeSink(sink);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPEngine::addThreadedSink(ThreadedSampleSink* sink, uint deviceIndex)
|
|
||||||
{
|
|
||||||
qDebug("DSPEngine::addThreadedSink(%d)", deviceIndex);
|
|
||||||
m_deviceEngines[deviceIndex]->addThreadedSink(sink);
|
|
||||||
}
|
|
||||||
|
|
||||||
void DSPEngine::removeThreadedSink(ThreadedSampleSink* sink, uint deviceIndex)
|
|
||||||
{
|
|
||||||
qDebug("DSPEngine::removeThreadedSink(%d)", deviceIndex);
|
|
||||||
m_deviceEngines[deviceIndex]->removeThreadedSink(sink);
|
|
||||||
}
|
|
||||||
|
|
||||||
void DSPEngine::addAudioSink(AudioFifo* audioFifo)
|
void DSPEngine::addAudioSink(AudioFifo* audioFifo)
|
||||||
{
|
{
|
||||||
qDebug("DSPEngine::addAudioSink");
|
qDebug("DSPEngine::addAudioSink");
|
||||||
|
@ -55,9 +55,6 @@ public:
|
|||||||
void addSink(SampleSink* sink, uint deviceIndex = 0); //!< Add a sample sink
|
void addSink(SampleSink* sink, uint deviceIndex = 0); //!< Add a sample sink
|
||||||
void removeSink(SampleSink* sink, uint deviceIndex = 0); //!< Remove a sample sink
|
void removeSink(SampleSink* sink, uint deviceIndex = 0); //!< Remove a sample sink
|
||||||
|
|
||||||
void addThreadedSink(ThreadedSampleSink* sink, uint deviceIndex = 0); //!< Add a sample sink that will run on its own thread
|
|
||||||
void removeThreadedSink(ThreadedSampleSink* sink, uint deviceIndex = 0); //!< Remove a sample sink that runs on its own thread
|
|
||||||
|
|
||||||
void configureCorrections(bool dcOffsetCorrection, bool iqImbalanceCorrection, uint deviceIndex = 0); //!< Configure DSP corrections
|
void configureCorrections(bool dcOffsetCorrection, bool iqImbalanceCorrection, uint deviceIndex = 0); //!< Configure DSP corrections
|
||||||
|
|
||||||
DSPDeviceEngine *getDeviceEngineByIndex(uint deviceIndex) { return m_deviceEngines[deviceIndex]; }
|
DSPDeviceEngine *getDeviceEngineByIndex(uint deviceIndex) { return m_deviceEngines[deviceIndex]; }
|
||||||
|
@ -115,7 +115,7 @@ MainWindow::MainWindow(QWidget* parent) :
|
|||||||
|
|
||||||
ui->tabSpectra->addTab(m_deviceUIs.back()->m_spectrum, "X0");
|
ui->tabSpectra->addTab(m_deviceUIs.back()->m_spectrum, "X0");
|
||||||
ui->tabSpectraGUI->addTab(m_deviceUIs.back()->m_spectrumGUI, "X0");
|
ui->tabSpectraGUI->addTab(m_deviceUIs.back()->m_spectrumGUI, "X0");
|
||||||
m_dspEngine->addSink(m_deviceUIs.back()->m_spectrumVis);
|
dspDeviceEngine->addSink(m_deviceUIs.back()->m_spectrumVis);
|
||||||
ui->tabChannels->addTab(m_deviceUIs.back()->m_channelWindow, "X0");
|
ui->tabChannels->addTab(m_deviceUIs.back()->m_channelWindow, "X0");
|
||||||
bool sampleSourceSignalsBlocked = m_deviceUIs.back()->m_sampleSource->blockSignals(true);
|
bool sampleSourceSignalsBlocked = m_deviceUIs.back()->m_sampleSource->blockSignals(true);
|
||||||
m_pluginManager->fillSampleSourceSelector(m_deviceUIs.back()->m_sampleSource);
|
m_pluginManager->fillSampleSourceSelector(m_deviceUIs.back()->m_sampleSource);
|
||||||
@ -124,7 +124,7 @@ MainWindow::MainWindow(QWidget* parent) :
|
|||||||
ui->tabInputs->addTab(m_deviceUIs.back()->m_sampleSource, "X0");
|
ui->tabInputs->addTab(m_deviceUIs.back()->m_sampleSource, "X0");
|
||||||
|
|
||||||
m_fileSink = new FileSink();
|
m_fileSink = new FileSink();
|
||||||
m_dspEngine->addSink(m_fileSink);
|
dspDeviceEngine->addSink(m_fileSink); // TODO: one file sink per device engine
|
||||||
|
|
||||||
qDebug() << "MainWindow::MainWindow: loadSettings...";
|
qDebug() << "MainWindow::MainWindow: loadSettings...";
|
||||||
|
|
||||||
@ -174,7 +174,7 @@ MainWindow::~MainWindow()
|
|||||||
delete m_deviceUIs[i];
|
delete m_deviceUIs[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
m_dspEngine->removeSink(m_fileSink);
|
m_dspEngine->removeSink(m_fileSink); // TODO: one file sink per device engine
|
||||||
//m_dspEngine->removeSink(m_rxSpectrumVis);
|
//m_dspEngine->removeSink(m_rxSpectrumVis);
|
||||||
delete m_fileSink;
|
delete m_fileSink;
|
||||||
//delete m_rxSpectrumVis;
|
//delete m_rxSpectrumVis;
|
||||||
|
Loading…
Reference in New Issue
Block a user