mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-27 02:09:14 -05:00
GUI segregation: Removed FileRecord reference in sample sink plugin GUIs
This commit is contained in:
parent
7ba47e7f3e
commit
0b4ee5cfcc
@ -25,7 +25,6 @@
|
|||||||
#include "dsp/dspengine.h"
|
#include "dsp/dspengine.h"
|
||||||
#include "dsp/dspcommands.h"
|
#include "dsp/dspcommands.h"
|
||||||
#include "device/devicesinkapi.h"
|
#include "device/devicesinkapi.h"
|
||||||
#include "dsp/filerecord.h"
|
|
||||||
#include "bladerfoutputgui.h"
|
#include "bladerfoutputgui.h"
|
||||||
#include "bladerf/devicebladerfvalues.h"
|
#include "bladerf/devicebladerfvalues.h"
|
||||||
|
|
||||||
@ -63,16 +62,12 @@ BladerfOutputGui::BladerfOutputGui(DeviceSinkAPI *deviceAPI, QWidget* parent) :
|
|||||||
|
|
||||||
char recFileNameCStr[30];
|
char recFileNameCStr[30];
|
||||||
sprintf(recFileNameCStr, "test_%d.sdriq", m_deviceAPI->getDeviceUID());
|
sprintf(recFileNameCStr, "test_%d.sdriq", m_deviceAPI->getDeviceUID());
|
||||||
m_fileSink = new FileRecord(std::string(recFileNameCStr));
|
|
||||||
// m_deviceAPI->addSink(m_fileSink);
|
|
||||||
|
|
||||||
connect(m_deviceAPI->getDeviceOutputMessageQueue(), SIGNAL(messageEnqueued()), this, SLOT(handleDSPMessages()), Qt::QueuedConnection);
|
connect(m_deviceAPI->getDeviceOutputMessageQueue(), SIGNAL(messageEnqueued()), this, SLOT(handleDSPMessages()), Qt::QueuedConnection);
|
||||||
}
|
}
|
||||||
|
|
||||||
BladerfOutputGui::~BladerfOutputGui()
|
BladerfOutputGui::~BladerfOutputGui()
|
||||||
{
|
{
|
||||||
// m_deviceAPI->removeSink(m_fileSink);
|
|
||||||
delete m_fileSink;
|
|
||||||
delete m_deviceSampleSink; // Valgrind memcheck
|
delete m_deviceSampleSink; // Valgrind memcheck
|
||||||
delete ui;
|
delete ui;
|
||||||
}
|
}
|
||||||
@ -156,7 +151,6 @@ void BladerfOutputGui::handleDSPMessages()
|
|||||||
m_deviceCenterFrequency = notif->getCenterFrequency();
|
m_deviceCenterFrequency = notif->getCenterFrequency();
|
||||||
qDebug("BladerfOutputGui::handleDSPMessages: SampleRate:%d, CenterFrequency:%llu", notif->getSampleRate(), notif->getCenterFrequency());
|
qDebug("BladerfOutputGui::handleDSPMessages: SampleRate:%d, CenterFrequency:%llu", notif->getSampleRate(), notif->getCenterFrequency());
|
||||||
updateSampleRateAndFrequency();
|
updateSampleRateAndFrequency();
|
||||||
m_fileSink->handleMessage(*notif); // forward to file sink
|
|
||||||
|
|
||||||
delete message;
|
delete message;
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,6 @@
|
|||||||
|
|
||||||
class DeviceSinkAPI;
|
class DeviceSinkAPI;
|
||||||
class DeviceSampleSink;
|
class DeviceSampleSink;
|
||||||
class FileRecord;
|
|
||||||
|
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
class BladerfOutputGui;
|
class BladerfOutputGui;
|
||||||
@ -57,7 +56,6 @@ private:
|
|||||||
QTimer m_updateTimer;
|
QTimer m_updateTimer;
|
||||||
QTimer m_statusTimer;
|
QTimer m_statusTimer;
|
||||||
DeviceSampleSink* m_deviceSampleSink;
|
DeviceSampleSink* m_deviceSampleSink;
|
||||||
FileRecord *m_fileSink; //!< File sink to record device I/Q output TODO: change to file input
|
|
||||||
int m_sampleRate;
|
int m_sampleRate;
|
||||||
quint64 m_deviceCenterFrequency; //!< Center frequency in device
|
quint64 m_deviceCenterFrequency; //!< Center frequency in device
|
||||||
int m_lastEngineState;
|
int m_lastEngineState;
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
#include "dsp/dspengine.h"
|
#include "dsp/dspengine.h"
|
||||||
#include "dsp/dspcommands.h"
|
#include "dsp/dspcommands.h"
|
||||||
#include "device/devicesinkapi.h"
|
#include "device/devicesinkapi.h"
|
||||||
#include "dsp/filerecord.h"
|
|
||||||
#include "limesdroutputgui.h"
|
#include "limesdroutputgui.h"
|
||||||
|
|
||||||
LimeSDROutputGUI::LimeSDROutputGUI(DeviceSinkAPI *deviceAPI, QWidget* parent) :
|
LimeSDROutputGUI::LimeSDROutputGUI(DeviceSinkAPI *deviceAPI, QWidget* parent) :
|
||||||
@ -76,14 +75,12 @@ LimeSDROutputGUI::LimeSDROutputGUI(DeviceSinkAPI *deviceAPI, QWidget* parent) :
|
|||||||
|
|
||||||
char recFileNameCStr[30];
|
char recFileNameCStr[30];
|
||||||
sprintf(recFileNameCStr, "test_%d.sdriq", m_deviceAPI->getDeviceUID());
|
sprintf(recFileNameCStr, "test_%d.sdriq", m_deviceAPI->getDeviceUID());
|
||||||
m_fileSink = new FileRecord(std::string(recFileNameCStr));
|
|
||||||
|
|
||||||
connect(m_deviceAPI->getDeviceOutputMessageQueue(), SIGNAL(messageEnqueued()), this, SLOT(handleMessagesToGUI()), Qt::QueuedConnection);
|
connect(m_deviceAPI->getDeviceOutputMessageQueue(), SIGNAL(messageEnqueued()), this, SLOT(handleMessagesToGUI()), Qt::QueuedConnection);
|
||||||
}
|
}
|
||||||
|
|
||||||
LimeSDROutputGUI::~LimeSDROutputGUI()
|
LimeSDROutputGUI::~LimeSDROutputGUI()
|
||||||
{
|
{
|
||||||
delete m_fileSink;
|
|
||||||
delete m_sampleSink; // Valgrind memcheck
|
delete m_sampleSink; // Valgrind memcheck
|
||||||
delete ui;
|
delete ui;
|
||||||
}
|
}
|
||||||
@ -161,7 +158,6 @@ void LimeSDROutputGUI::handleMessagesToGUI()
|
|||||||
m_deviceCenterFrequency = notif->getCenterFrequency();
|
m_deviceCenterFrequency = notif->getCenterFrequency();
|
||||||
qDebug("LimeSDROutputGUI::handleMessagesToGUI: SampleRate: %d, CenterFrequency: %llu", notif->getSampleRate(), notif->getCenterFrequency());
|
qDebug("LimeSDROutputGUI::handleMessagesToGUI: SampleRate: %d, CenterFrequency: %llu", notif->getSampleRate(), notif->getCenterFrequency());
|
||||||
updateSampleRateAndFrequency();
|
updateSampleRateAndFrequency();
|
||||||
m_fileSink->handleMessage(*notif); // forward to file sink
|
|
||||||
|
|
||||||
delete message;
|
delete message;
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,6 @@
|
|||||||
|
|
||||||
class DeviceSinkAPI;
|
class DeviceSinkAPI;
|
||||||
class DeviceSampleSink;
|
class DeviceSampleSink;
|
||||||
class FileRecord;
|
|
||||||
|
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
class LimeSDROutputGUI;
|
class LimeSDROutputGUI;
|
||||||
@ -58,7 +57,6 @@ private:
|
|||||||
QTimer m_updateTimer;
|
QTimer m_updateTimer;
|
||||||
QTimer m_statusTimer;
|
QTimer m_statusTimer;
|
||||||
DeviceSampleSink* m_sampleSink;
|
DeviceSampleSink* m_sampleSink;
|
||||||
FileRecord *m_fileSink; //!< File sink to record device I/Q output TODO: change to file input
|
|
||||||
int m_sampleRate;
|
int m_sampleRate;
|
||||||
quint64 m_deviceCenterFrequency; //!< Center frequency in device
|
quint64 m_deviceCenterFrequency; //!< Center frequency in device
|
||||||
int m_lastEngineState;
|
int m_lastEngineState;
|
||||||
|
Loading…
Reference in New Issue
Block a user