mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-07-05 10:25:32 -04:00
Removed SyncMessenger from DSPDeviceSinkEngine. Part of #2159
This commit is contained in:
parent
2b26f15463
commit
d553834adf
@ -39,16 +39,15 @@ DSPDeviceSinkEngine::DSPDeviceSinkEngine(uint32_t uid, QObject* parent) :
|
|||||||
m_centerFrequency(0),
|
m_centerFrequency(0),
|
||||||
m_realElseComplex(false)
|
m_realElseComplex(false)
|
||||||
{
|
{
|
||||||
|
setState(StIdle);
|
||||||
connect(&m_inputMessageQueue, SIGNAL(messageEnqueued()), this, SLOT(handleInputMessages()), Qt::QueuedConnection);
|
connect(&m_inputMessageQueue, SIGNAL(messageEnqueued()), this, SLOT(handleInputMessages()), Qt::QueuedConnection);
|
||||||
connect(&m_syncMessenger, SIGNAL(messageSent()), this, SLOT(handleSynchronousMessages()), Qt::QueuedConnection);
|
|
||||||
|
|
||||||
moveToThread(this);
|
moveToThread(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
DSPDeviceSinkEngine::~DSPDeviceSinkEngine()
|
DSPDeviceSinkEngine::~DSPDeviceSinkEngine()
|
||||||
{
|
{
|
||||||
stop();
|
qDebug("DSPDeviceSinkEngine::~DSPDeviceSinkEngine");
|
||||||
wait();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::setState(State state)
|
void DSPDeviceSinkEngine::setState(State state)
|
||||||
@ -86,32 +85,32 @@ void DSPDeviceSinkEngine::stop()
|
|||||||
bool DSPDeviceSinkEngine::initGeneration()
|
bool DSPDeviceSinkEngine::initGeneration()
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::initGeneration";
|
qDebug() << "DSPDeviceSinkEngine::initGeneration";
|
||||||
DSPGenerationInit cmd;
|
auto *cmd = new DSPGenerationInit();
|
||||||
|
getInputMessageQueue()->push(cmd);
|
||||||
return m_syncMessenger.sendWait(cmd) == StReady;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool DSPDeviceSinkEngine::startGeneration()
|
bool DSPDeviceSinkEngine::startGeneration()
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::startGeneration";
|
qDebug() << "DSPDeviceSinkEngine::startGeneration";
|
||||||
DSPGenerationStart cmd;
|
auto *cmd = new DSPGenerationStart();
|
||||||
|
getInputMessageQueue()->push(cmd);
|
||||||
return m_syncMessenger.sendWait(cmd) == StRunning;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::stopGeneration()
|
void DSPDeviceSinkEngine::stopGeneration()
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::stopGeneration";
|
qDebug() << "DSPDeviceSinkEngine::stopGeneration";
|
||||||
DSPGenerationStop cmd;
|
DSPGenerationStop *cmd = new DSPGenerationStop();
|
||||||
m_syncMessenger.storeMessage(cmd);
|
getInputMessageQueue()->push(cmd);
|
||||||
handleSynchronousMessages();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::setSink(DeviceSampleSink* sink)
|
void DSPDeviceSinkEngine::setSink(DeviceSampleSink* sink)
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::setSink";
|
qDebug() << "DSPDeviceSinkEngine::setSink";
|
||||||
DSPSetSink cmd(sink);
|
m_deviceSampleSink = sink;
|
||||||
m_syncMessenger.sendWait(cmd);
|
auto *cmd = new DSPSetSink(sink);
|
||||||
|
getInputMessageQueue()->push(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::setSinkSequence(int sequence)
|
void DSPDeviceSinkEngine::setSinkSequence(int sequence)
|
||||||
@ -123,45 +122,40 @@ void DSPDeviceSinkEngine::setSinkSequence(int sequence)
|
|||||||
void DSPDeviceSinkEngine::addChannelSource(BasebandSampleSource* source)
|
void DSPDeviceSinkEngine::addChannelSource(BasebandSampleSource* source)
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::addChannelSource: " << source->getSourceName().toStdString().c_str();
|
qDebug() << "DSPDeviceSinkEngine::addChannelSource: " << source->getSourceName().toStdString().c_str();
|
||||||
DSPAddBasebandSampleSource cmd(source);
|
DSPAddBasebandSampleSource *cmd = new DSPAddBasebandSampleSource(source);
|
||||||
m_syncMessenger.sendWait(cmd);
|
getInputMessageQueue()->push(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::removeChannelSource(BasebandSampleSource* source)
|
void DSPDeviceSinkEngine::removeChannelSource(BasebandSampleSource* source)
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::removeChannelSource: " << source->getSourceName().toStdString().c_str();
|
qDebug() << "DSPDeviceSinkEngine::removeChannelSource: " << source->getSourceName().toStdString().c_str();
|
||||||
DSPRemoveBasebandSampleSource cmd(source);
|
auto *cmd = new DSPRemoveBasebandSampleSource(source);
|
||||||
m_syncMessenger.sendWait(cmd);
|
getInputMessageQueue()->push(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::addSpectrumSink(BasebandSampleSink* spectrumSink)
|
void DSPDeviceSinkEngine::addSpectrumSink(BasebandSampleSink* spectrumSink)
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::addSpectrumSink: " << spectrumSink->getSinkName().toStdString().c_str();
|
qDebug() << "DSPDeviceSinkEngine::addSpectrumSink: " << spectrumSink->getSinkName().toStdString().c_str();
|
||||||
DSPAddSpectrumSink cmd(spectrumSink);
|
m_spectrumSink = spectrumSink;
|
||||||
m_syncMessenger.sendWait(cmd);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::removeSpectrumSink(BasebandSampleSink* spectrumSink)
|
void DSPDeviceSinkEngine::removeSpectrumSink(BasebandSampleSink* spectrumSink)
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::removeSpectrumSink: " << spectrumSink->getSinkName().toStdString().c_str();
|
qDebug() << "DSPDeviceSinkEngine::removeSpectrumSink: " << spectrumSink->getSinkName().toStdString().c_str();
|
||||||
DSPRemoveSpectrumSink cmd(spectrumSink);
|
auto *cmd = new DSPRemoveSpectrumSink(spectrumSink);
|
||||||
m_syncMessenger.sendWait(cmd);
|
getInputMessageQueue()->push(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString DSPDeviceSinkEngine::errorMessage()
|
QString DSPDeviceSinkEngine::errorMessage()
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::errorMessage";
|
qDebug() << "DSPDeviceSinkEngine::errorMessage";
|
||||||
DSPGetErrorMessage cmd;
|
return m_errorMessage;
|
||||||
m_syncMessenger.sendWait(cmd);
|
|
||||||
return cmd.getErrorMessage();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QString DSPDeviceSinkEngine::sinkDeviceDescription()
|
QString DSPDeviceSinkEngine::sinkDeviceDescription()
|
||||||
{
|
{
|
||||||
qDebug() << "DSPDeviceSinkEngine::sinkDeviceDescription";
|
qDebug() << "DSPDeviceSinkEngine::sinkDeviceDescription";
|
||||||
DSPGetSinkDeviceDescription cmd;
|
return m_deviceDescription;
|
||||||
m_syncMessenger.sendWait(cmd);
|
|
||||||
return cmd.getDeviceDescription();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::workSampleFifo()
|
void DSPDeviceSinkEngine::workSampleFifo()
|
||||||
@ -399,15 +393,13 @@ DSPDeviceSinkEngine::State DSPDeviceSinkEngine::gotoError(const QString& errorMe
|
|||||||
return StError;
|
return StError;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::handleSetSink(DeviceSampleSink* sink)
|
void DSPDeviceSinkEngine::handleSetSink(DeviceSampleSink*)
|
||||||
{
|
{
|
||||||
m_deviceSampleSink = sink;
|
|
||||||
|
|
||||||
if (!m_deviceSampleSink) { // Early leave
|
if (!m_deviceSampleSink) { // Early leave
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
qDebug("DSPDeviceSinkEngine::handleSetSink: set %s", qPrintable(sink->getDeviceDescription()));
|
qDebug("DSPDeviceSinkEngine::handleSetSink: set %s", qPrintable(m_deviceSampleSink->getDeviceDescription()));
|
||||||
|
|
||||||
QObject::connect(
|
QObject::connect(
|
||||||
m_deviceSampleSink->getSampleFifo(),
|
m_deviceSampleSink->getSampleFifo(),
|
||||||
@ -416,7 +408,6 @@ void DSPDeviceSinkEngine::handleSetSink(DeviceSampleSink* sink)
|
|||||||
&DSPDeviceSinkEngine::handleData,
|
&DSPDeviceSinkEngine::handleData,
|
||||||
Qt::QueuedConnection
|
Qt::QueuedConnection
|
||||||
);
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::handleData()
|
void DSPDeviceSinkEngine::handleData()
|
||||||
@ -426,97 +417,17 @@ void DSPDeviceSinkEngine::handleData()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::handleSynchronousMessages()
|
bool DSPDeviceSinkEngine::handleMessage(const Message& message)
|
||||||
{
|
{
|
||||||
Message *message = m_syncMessenger.getMessage();
|
if (DSPSignalNotification::match(message))
|
||||||
qDebug() << "DSPDeviceSinkEngine::handleSynchronousMessages: " << message->getIdentifier();
|
|
||||||
|
|
||||||
if (DSPGenerationInit::match(*message))
|
|
||||||
{
|
{
|
||||||
setState(gotoIdle());
|
const DSPSignalNotification& notif = (const DSPSignalNotification&) message;
|
||||||
|
|
||||||
if(m_state == StIdle) {
|
|
||||||
setState(gotoInit()); // State goes ready if init is performed
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (DSPGenerationStart::match(*message))
|
|
||||||
{
|
|
||||||
if(m_state == StReady) {
|
|
||||||
setState(gotoRunning());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (DSPGenerationStop::match(*message))
|
|
||||||
{
|
|
||||||
setState(gotoIdle());
|
|
||||||
}
|
|
||||||
else if (DSPGetSinkDeviceDescription::match(*message))
|
|
||||||
{
|
|
||||||
((DSPGetSinkDeviceDescription*) message)->setDeviceDescription(m_deviceDescription);
|
|
||||||
}
|
|
||||||
else if (DSPGetErrorMessage::match(*message))
|
|
||||||
{
|
|
||||||
((DSPGetErrorMessage*) message)->setErrorMessage(m_errorMessage);
|
|
||||||
}
|
|
||||||
else if (DSPSetSink::match(*message)) {
|
|
||||||
handleSetSink(((DSPSetSink*) message)->getSampleSink());
|
|
||||||
}
|
|
||||||
else if (DSPAddSpectrumSink::match(*message))
|
|
||||||
{
|
|
||||||
m_spectrumSink = ((DSPAddSpectrumSink*) message)->getSampleSink();
|
|
||||||
}
|
|
||||||
else if (DSPRemoveSpectrumSink::match(*message))
|
|
||||||
{
|
|
||||||
BasebandSampleSink* spectrumSink = ((DSPRemoveSpectrumSink*) message)->getSampleSink();
|
|
||||||
|
|
||||||
if(m_state == StRunning) {
|
|
||||||
spectrumSink->stop();
|
|
||||||
}
|
|
||||||
|
|
||||||
m_spectrumSink = nullptr;
|
|
||||||
}
|
|
||||||
else if (DSPAddBasebandSampleSource::match(*message))
|
|
||||||
{
|
|
||||||
BasebandSampleSource* source = ((DSPAddBasebandSampleSource*) message)->getSampleSource();
|
|
||||||
m_basebandSampleSources.push_back(source);
|
|
||||||
DSPSignalNotification *notif = new DSPSignalNotification(m_sampleRate, m_centerFrequency);
|
|
||||||
source->pushMessage(notif);
|
|
||||||
|
|
||||||
if (m_state == StRunning)
|
|
||||||
{
|
|
||||||
source->start();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (DSPRemoveBasebandSampleSource::match(*message))
|
|
||||||
{
|
|
||||||
BasebandSampleSource* source = ((DSPRemoveBasebandSampleSource*) message)->getSampleSource();
|
|
||||||
|
|
||||||
if(m_state == StRunning) {
|
|
||||||
source->stop();
|
|
||||||
}
|
|
||||||
|
|
||||||
m_basebandSampleSources.remove(source);
|
|
||||||
}
|
|
||||||
|
|
||||||
m_syncMessenger.done(m_state);
|
|
||||||
}
|
|
||||||
|
|
||||||
void DSPDeviceSinkEngine::handleInputMessages()
|
|
||||||
{
|
|
||||||
Message* message;
|
|
||||||
|
|
||||||
while ((message = m_inputMessageQueue.pop()) != 0)
|
|
||||||
{
|
|
||||||
qDebug("DSPDeviceSinkEngine::handleInputMessages: message: %s", message->getIdentifier());
|
|
||||||
|
|
||||||
if (DSPSignalNotification::match(*message))
|
|
||||||
{
|
|
||||||
DSPSignalNotification *notif = (DSPSignalNotification *) message;
|
|
||||||
|
|
||||||
// update DSP values
|
// update DSP values
|
||||||
|
|
||||||
m_sampleRate = notif->getSampleRate();
|
m_sampleRate = notif.getSampleRate();
|
||||||
m_centerFrequency = notif->getCenterFrequency();
|
m_centerFrequency = notif.getCenterFrequency();
|
||||||
m_realElseComplex = notif->getRealElseComplex();
|
m_realElseComplex = notif.getRealElseComplex();
|
||||||
|
|
||||||
qDebug() << "DSPDeviceSinkEngine::handleInputMessages: DSPSignalNotification:"
|
qDebug() << "DSPDeviceSinkEngine::handleInputMessages: DSPSignalNotification:"
|
||||||
<< " m_sampleRate: " << m_sampleRate
|
<< " m_sampleRate: " << m_sampleRate
|
||||||
@ -527,7 +438,7 @@ void DSPDeviceSinkEngine::handleInputMessages()
|
|||||||
|
|
||||||
for(BasebandSampleSources::const_iterator it = m_basebandSampleSources.begin(); it != m_basebandSampleSources.end(); it++)
|
for(BasebandSampleSources::const_iterator it = m_basebandSampleSources.begin(); it != m_basebandSampleSources.end(); it++)
|
||||||
{
|
{
|
||||||
DSPSignalNotification* rep = new DSPSignalNotification(*notif); // make a copy
|
auto *rep = new DSPSignalNotification(notif); // make a copy
|
||||||
qDebug() << "DSPDeviceSinkEngine::handleInputMessages: forward message to " << (*it)->getSourceName().toStdString().c_str();
|
qDebug() << "DSPDeviceSinkEngine::handleInputMessages: forward message to " << (*it)->getSourceName().toStdString().c_str();
|
||||||
(*it)->pushMessage(rep);
|
(*it)->pushMessage(rep);
|
||||||
}
|
}
|
||||||
@ -540,11 +451,93 @@ void DSPDeviceSinkEngine::handleInputMessages()
|
|||||||
|
|
||||||
if (guiMessageQueue)
|
if (guiMessageQueue)
|
||||||
{
|
{
|
||||||
DSPSignalNotification* rep = new DSPSignalNotification(*notif); // make a copy for the output queue
|
auto *rep = new DSPSignalNotification(notif); // make a copy for the output queue
|
||||||
guiMessageQueue->push(rep);
|
guiMessageQueue->push(rep);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
// From synchronous messages
|
||||||
|
if (DSPGenerationInit::match(message))
|
||||||
|
{
|
||||||
|
setState(gotoIdle());
|
||||||
|
|
||||||
|
if(m_state == StIdle) {
|
||||||
|
setState(gotoInit()); // State goes ready if init is performed
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (DSPGenerationStart::match(message))
|
||||||
|
{
|
||||||
|
if(m_state == StReady) {
|
||||||
|
setState(gotoRunning());
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (DSPGenerationStop::match(message))
|
||||||
|
{
|
||||||
|
setState(gotoIdle());
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (DSPSetSink::match(message))
|
||||||
|
{
|
||||||
|
const DSPSetSink& cmd = (const DSPSetSink&) message;
|
||||||
|
handleSetSink(cmd.getSampleSink());
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (DSPRemoveSpectrumSink::match(message))
|
||||||
|
{
|
||||||
|
auto& cmd = (const DSPRemoveSpectrumSink&) message;
|
||||||
|
BasebandSampleSink* spectrumSink = cmd.getSampleSink();
|
||||||
|
|
||||||
|
if(m_state == StRunning) {
|
||||||
|
spectrumSink->stop();
|
||||||
|
}
|
||||||
|
|
||||||
|
m_spectrumSink = nullptr;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (DSPAddBasebandSampleSource::match(message))
|
||||||
|
{
|
||||||
|
auto& cmd = (const DSPAddBasebandSampleSource&) message;
|
||||||
|
BasebandSampleSource* source = cmd.getSampleSource();
|
||||||
|
m_basebandSampleSources.push_back(source);
|
||||||
|
auto *notif = new DSPSignalNotification(m_sampleRate, m_centerFrequency);
|
||||||
|
source->pushMessage(notif);
|
||||||
|
|
||||||
|
if (m_state == StRunning) {
|
||||||
|
source->start();
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (DSPRemoveBasebandSampleSource::match(message))
|
||||||
|
{
|
||||||
|
auto& cmd = (const DSPRemoveBasebandSampleSource&) message;
|
||||||
|
BasebandSampleSource* source = cmd.getSampleSource();
|
||||||
|
|
||||||
|
if(m_state == StRunning) {
|
||||||
|
source->stop();
|
||||||
|
}
|
||||||
|
|
||||||
|
m_basebandSampleSources.remove(source);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void DSPDeviceSinkEngine::handleInputMessages()
|
||||||
|
{
|
||||||
|
Message* message;
|
||||||
|
|
||||||
|
while ((message = m_inputMessageQueue.pop()) != nullptr)
|
||||||
|
{
|
||||||
|
qDebug("DSPDeviceSinkEngine::handleInputMessages: message: %s", message->getIdentifier());
|
||||||
|
if (handleMessage(*message)) {
|
||||||
delete message;
|
delete message;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,7 +33,6 @@
|
|||||||
|
|
||||||
#include "dsp/dsptypes.h"
|
#include "dsp/dsptypes.h"
|
||||||
#include "util/messagequeue.h"
|
#include "util/messagequeue.h"
|
||||||
#include "util/syncmessenger.h"
|
|
||||||
#include "util/incrementalvector.h"
|
#include "util/incrementalvector.h"
|
||||||
#include "export.h"
|
#include "export.h"
|
||||||
|
|
||||||
@ -86,7 +85,6 @@ private:
|
|||||||
uint32_t m_uid; //!< unique ID
|
uint32_t m_uid; //!< unique ID
|
||||||
|
|
||||||
MessageQueue m_inputMessageQueue; //<! Input message queue. Post here.
|
MessageQueue m_inputMessageQueue; //<! Input message queue. Post here.
|
||||||
SyncMessenger m_syncMessenger; //!< Used to process messages synchronously with the thread
|
|
||||||
|
|
||||||
State m_state;
|
State m_state;
|
||||||
|
|
||||||
@ -119,11 +117,11 @@ private:
|
|||||||
void setState(State state);
|
void setState(State state);
|
||||||
|
|
||||||
void handleSetSink(DeviceSampleSink* sink); //!< Manage sink setting
|
void handleSetSink(DeviceSampleSink* sink); //!< Manage sink setting
|
||||||
|
bool handleMessage(const Message& cmd);
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void handleData(); //!< Handle data when samples have to be written to the sample FIFO
|
void handleData(); //!< Handle data when samples have to be written to the sample FIFO
|
||||||
void handleInputMessages(); //!< Handle input message queue
|
void handleInputMessages(); //!< Handle input message queue
|
||||||
void handleSynchronousMessages(); //!< Handle synchronous messages with the thread
|
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void stateChanged();
|
void stateChanged();
|
||||||
|
@ -1106,7 +1106,6 @@ void MainWindow::removeLastDeviceSet()
|
|||||||
m_deviceUIs.back()->m_deviceAPI->resetSamplingDeviceId();
|
m_deviceUIs.back()->m_deviceAPI->resetSamplingDeviceId();
|
||||||
m_deviceUIs.back()->m_deviceAPI->clearBuddiesLists(); // clear old API buddies lists
|
m_deviceUIs.back()->m_deviceAPI->clearBuddiesLists(); // clear old API buddies lists
|
||||||
|
|
||||||
|
|
||||||
m_dspEngine->removeLastDeviceSourceEngine();
|
m_dspEngine->removeLastDeviceSourceEngine();
|
||||||
|
|
||||||
DeviceAPI *sourceAPI = m_deviceUIs.back()->m_deviceAPI;
|
DeviceAPI *sourceAPI = m_deviceUIs.back()->m_deviceAPI;
|
||||||
@ -1125,16 +1124,13 @@ void MainWindow::removeLastDeviceSet()
|
|||||||
m_deviceUIs.back()->m_deviceAPI->getSampleSink()->setMessageQueueToGUI(nullptr); // have sink stop sending messages to the GUI
|
m_deviceUIs.back()->m_deviceAPI->getSampleSink()->setMessageQueueToGUI(nullptr); // have sink stop sending messages to the GUI
|
||||||
m_deviceUIs.back()->m_deviceGUI->destroy();
|
m_deviceUIs.back()->m_deviceGUI->destroy();
|
||||||
m_deviceUIs.back()->m_deviceAPI->resetSamplingDeviceId();
|
m_deviceUIs.back()->m_deviceAPI->resetSamplingDeviceId();
|
||||||
m_deviceUIs.back()->m_deviceAPI->getPluginInterface()->deleteSampleSinkPluginInstanceOutput(
|
|
||||||
m_deviceUIs.back()->m_deviceAPI->getSampleSink());
|
|
||||||
m_deviceUIs.back()->m_deviceAPI->clearBuddiesLists(); // clear old API buddies lists
|
m_deviceUIs.back()->m_deviceAPI->clearBuddiesLists(); // clear old API buddies lists
|
||||||
|
|
||||||
|
m_dspEngine->removeLastDeviceSinkEngine();
|
||||||
|
|
||||||
DeviceAPI *sinkAPI = m_deviceUIs.back()->m_deviceAPI;
|
DeviceAPI *sinkAPI = m_deviceUIs.back()->m_deviceAPI;
|
||||||
delete m_deviceUIs.back();
|
delete m_deviceUIs.back();
|
||||||
|
delete sinkAPI->getSampleSink();
|
||||||
lastDeviceEngine->stop();
|
|
||||||
m_dspEngine->removeLastDeviceSinkEngine();
|
|
||||||
|
|
||||||
delete sinkAPI;
|
delete sinkAPI;
|
||||||
}
|
}
|
||||||
else if (m_deviceUIs.back()->m_deviceMIMOEngine) // MIMO tab
|
else if (m_deviceUIs.back()->m_deviceMIMOEngine) // MIMO tab
|
||||||
|
Loading…
x
Reference in New Issue
Block a user