1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-24 00:48:41 -05:00

Fix PR comments

This commit is contained in:
DreamNik 2024-09-09 18:48:54 +03:00
parent 60e1d1cd9e
commit d2e89b7337
59 changed files with 60 additions and 95 deletions

View File

@ -49,7 +49,7 @@ ChannelPower::ChannelPower(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new ChannelPowerBaseband(this);
m_basebandSink = new ChannelPowerBaseband();
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -25,8 +25,7 @@
MESSAGE_CLASS_DEFINITION(ChannelPowerBaseband::MsgConfigureChannelPowerBaseband, Message)
ChannelPowerBaseband::ChannelPowerBaseband(ChannelPower *channelPower) :
m_sink(channelPower),
ChannelPowerBaseband::ChannelPowerBaseband() :
m_running(false)
{
qDebug("ChannelPowerBaseband::ChannelPowerBaseband");

View File

@ -62,7 +62,7 @@ public:
{ }
};
ChannelPowerBaseband(ChannelPower *channelPower);
ChannelPowerBaseband();
~ChannelPowerBaseband();
void reset();
void startWork();

View File

@ -20,14 +20,12 @@
#include "channelpowersink.h"
ChannelPowerSink::ChannelPowerSink(ChannelPower *channelPower) :
ChannelPowerSink::ChannelPowerSink() :
m_channelSampleRate(10000),
m_channelFrequencyOffset(0),
m_lowpassFFT(nullptr),
m_lowpassBufferIdx(0)
{
(void)channelPower;
resetMagLevels();
applySettings(m_settings, QStringList(), true);

View File

@ -32,7 +32,7 @@ class ChannelPower;
class ChannelPowerSink : public ChannelSampleSink {
public:
ChannelPowerSink(ChannelPower *channelPower);
ChannelPowerSink();
~ChannelPowerSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -812,9 +812,7 @@ public:
m_aircraftRegExp.optimize();
}
virtual ~ModelMatch()
{
}
virtual ~ModelMatch() = default;
virtual bool match(const QString &aircraft, const QString &manufacturer, QString &model)
{

View File

@ -55,7 +55,7 @@ APTDemod::APTDemod(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new APTDemodBaseband(this);
m_basebandSink = new APTDemodBaseband();
m_basebandSink->moveToThread(&m_thread);
m_imageWorker = new APTDemodImageWorker(this);

View File

@ -26,8 +26,7 @@
MESSAGE_CLASS_DEFINITION(APTDemodBaseband::MsgConfigureAPTDemodBaseband, Message)
APTDemodBaseband::APTDemodBaseband(APTDemod *packetDemod) :
m_sink(packetDemod),
APTDemodBaseband::APTDemodBaseband() :
m_running(false)
{
qDebug("APTDemodBaseband::APTDemodBaseband");

View File

@ -58,7 +58,7 @@ public:
{ }
};
APTDemodBaseband(APTDemod *packetDemod);
APTDemodBaseband();
~APTDemodBaseband();
void reset();
void startWork();

View File

@ -23,7 +23,7 @@
#include "aptdemod.h"
#include "aptdemodsink.h"
APTDemodSink::APTDemodSink(APTDemod *packetDemod) :
APTDemodSink::APTDemodSink() :
m_channelSampleRate(APTDEMOD_AUDIO_SAMPLE_RATE),
m_channelFrequencyOffset(0),
m_magsqSum(0.0f),
@ -32,7 +32,6 @@ APTDemodSink::APTDemodSink(APTDemod *packetDemod) :
m_imageWorkerMessageQueue(nullptr),
m_samples(nullptr)
{
(void)packetDemod;
m_magsq = 0.0;

View File

@ -44,7 +44,7 @@ class APTDemod;
class APTDemodSink : public ChannelSampleSink {
public:
APTDemodSink(APTDemod *packetDemod);
APTDemodSink();
~APTDemodSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -64,7 +64,7 @@ DABDemod::DABDemod(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new DABDemodBaseband(this);
m_basebandSink = new DABDemodBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -28,8 +28,7 @@
MESSAGE_CLASS_DEFINITION(DABDemodBaseband::MsgConfigureDABDemodBaseband, Message)
DABDemodBaseband::DABDemodBaseband(DABDemod *packetDemod) :
m_sink(packetDemod),
DABDemodBaseband::DABDemodBaseband() :
m_running(false)
{
qDebug("DABDemodBaseband::DABDemodBaseband");

View File

@ -60,7 +60,7 @@ public:
{ }
};
DABDemodBaseband(DABDemod *packetDemod);
DABDemodBaseband();
~DABDemodBaseband();
void reset();
void startWork();

View File

@ -487,7 +487,7 @@ void DABDemodSink::processOneAudioSample(Complex &ci)
}
}
DABDemodSink::DABDemodSink(DABDemod *packetDemod) :
DABDemodSink::DABDemodSink() :
m_audioSampleRate(48000),
m_dabAudioSampleRate(10000), // Unused value to begin with
m_channelSampleRate(DABDEMOD_CHANNEL_SAMPLE_RATE),
@ -499,8 +499,6 @@ DABDemodSink::DABDemodSink(DABDemod *packetDemod) :
m_messageQueueToChannel(nullptr),
m_audioFifo(48000)
{
(void)packetDemod;
m_audioBuffer.resize(1<<14);
m_audioBufferFill = 0;

View File

@ -43,7 +43,7 @@ class DABDemod;
class DABDemodSink : public ChannelSampleSink {
public:
DABDemodSink(DABDemod *packetDemod);
DABDemodSink();
~DABDemodSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -61,7 +61,7 @@ ILSDemod::ILSDemod(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new ILSDemodBaseband(this);
m_basebandSink = new ILSDemodBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -27,8 +27,7 @@
MESSAGE_CLASS_DEFINITION(ILSDemodBaseband::MsgConfigureILSDemodBaseband, Message)
ILSDemodBaseband::ILSDemodBaseband(ILSDemod *packetDemod) :
m_sink(packetDemod),
ILSDemodBaseband::ILSDemodBaseband() :
m_running(false)
{
qDebug("ILSDemodBaseband::ILSDemodBaseband");

View File

@ -63,7 +63,7 @@ public:
{ }
};
ILSDemodBaseband(ILSDemod *packetDemod);
ILSDemodBaseband();
~ILSDemodBaseband();
void reset();
void startWork();

View File

@ -28,7 +28,7 @@
#include "ilsdemod.h"
#include "ilsdemodsink.h"
ILSDemodSink::ILSDemodSink(ILSDemod *ilsDemod) :
ILSDemodSink::ILSDemodSink() :
m_spectrumSink(nullptr),
m_scopeSink(nullptr),
m_channel(nullptr),
@ -50,8 +50,6 @@ ILSDemodSink::ILSDemodSink(ILSDemod *ilsDemod) :
m_audioFifo(48000),
m_sampleBufferIndex(0)
{
(void)ilsDemod;
m_audioBuffer.resize(1<<14);
m_audioBufferFill = 0;

View File

@ -44,7 +44,7 @@ class SpectrumVis;
class ILSDemodSink : public ChannelSampleSink {
public:
ILSDemodSink(ILSDemod *packetDemod);
ILSDemodSink();
~ILSDemodSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -53,7 +53,7 @@ NavtexDemod::NavtexDemod(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new NavtexDemodBaseband(this);
m_basebandSink = new NavtexDemodBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -26,8 +26,7 @@
MESSAGE_CLASS_DEFINITION(NavtexDemodBaseband::MsgConfigureNavtexDemodBaseband, Message)
NavtexDemodBaseband::NavtexDemodBaseband(NavtexDemod *navtexDemod) :
m_sink(navtexDemod),
NavtexDemodBaseband::NavtexDemodBaseband() :
m_running(false)
{
qDebug("NavtexDemodBaseband::NavtexDemodBaseband");

View File

@ -62,7 +62,7 @@ public:
{ }
};
NavtexDemodBaseband(NavtexDemod *navtexDemod);
NavtexDemodBaseband();
~NavtexDemodBaseband();
void reset();
void startWork();

View File

@ -27,7 +27,7 @@
#include "navtexdemod.h"
#include "navtexdemodsink.h"
NavtexDemodSink::NavtexDemodSink(NavtexDemod *packetDemod) :
NavtexDemodSink::NavtexDemodSink() :
m_channelSampleRate(NavtexDemodSettings::NAVTEXDEMOD_CHANNEL_SAMPLE_RATE),
m_channelFrequencyOffset(0),
m_magsqSum(0.0f),
@ -37,7 +37,6 @@ NavtexDemodSink::NavtexDemodSink(NavtexDemod *packetDemod) :
m_exp(nullptr),
m_sampleBufferIndex(0)
{
(void)packetDemod;
m_magsq = 0.0;
m_sampleBuffer.resize(m_sampleBufferSize);

View File

@ -39,7 +39,7 @@ class ScopeVis;
class NavtexDemodSink : public ChannelSampleSink {
public:
NavtexDemodSink(NavtexDemod *packetDemod);
NavtexDemodSink();
~NavtexDemodSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -46,7 +46,7 @@ PagerDemod::PagerDemod(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new PagerDemodBaseband(this);
m_basebandSink = new PagerDemodBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -26,8 +26,7 @@
MESSAGE_CLASS_DEFINITION(PagerDemodBaseband::MsgConfigurePagerDemodBaseband, Message)
PagerDemodBaseband::PagerDemodBaseband(PagerDemod *pagerDemod) :
m_sink(pagerDemod),
PagerDemodBaseband::PagerDemodBaseband() :
m_running(false)
{
qDebug("PagerDemodBaseband::PagerDemodBaseband");

View File

@ -62,7 +62,7 @@ public:
{ }
};
PagerDemodBaseband(PagerDemod *pagerDemod);
PagerDemodBaseband();
~PagerDemodBaseband();
void reset();
void startWork();

View File

@ -28,7 +28,7 @@
#include "pagerdemod.h"
#include "pagerdemodsink.h"
PagerDemodSink::PagerDemodSink(PagerDemod *pagerDemod) :
PagerDemodSink::PagerDemodSink() :
m_scopeSink(nullptr),
m_channelSampleRate(PagerDemodSettings::m_channelSampleRate),
m_channelFrequencyOffset(0),
@ -49,8 +49,6 @@ PagerDemodSink::PagerDemodSink(PagerDemod *pagerDemod) :
m_addressValid(0),
m_sampleBufferIndex(0)
{
(void)pagerDemod;
m_magsq = 0.0;
m_demodBuffer.resize(1<<12);

View File

@ -45,7 +45,7 @@ class ScopeVis;
class PagerDemodSink : public ChannelSampleSink {
public:
PagerDemodSink(PagerDemod *pagerDemod);
PagerDemodSink();
~PagerDemodSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -53,7 +53,7 @@ RttyDemod::RttyDemod(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new RttyDemodBaseband(this);
m_basebandSink = new RttyDemodBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -26,8 +26,7 @@
MESSAGE_CLASS_DEFINITION(RttyDemodBaseband::MsgConfigureRttyDemodBaseband, Message)
RttyDemodBaseband::RttyDemodBaseband(RttyDemod *rttyDemod) :
m_sink(rttyDemod),
RttyDemodBaseband::RttyDemodBaseband() :
m_running(false)
{
qDebug("RttyDemodBaseband::RttyDemodBaseband");

View File

@ -62,7 +62,7 @@ public:
{ }
};
RttyDemodBaseband(RttyDemod *rttyDemod);
RttyDemodBaseband();
~RttyDemodBaseband();
void reset();
void startWork();

View File

@ -28,7 +28,7 @@
#include "rttydemod.h"
#include "rttydemodsink.h"
RttyDemodSink::RttyDemodSink(RttyDemod *packetDemod) :
RttyDemodSink::RttyDemodSink() :
m_channelSampleRate(RttyDemodSettings::RTTYDEMOD_CHANNEL_SAMPLE_RATE),
m_channelFrequencyOffset(0),
m_magsqSum(0.0f),
@ -47,8 +47,6 @@ RttyDemodSink::RttyDemodSink(RttyDemod *packetDemod) :
m_fftCounter(0),
m_sampleBufferIndex(0)
{
(void)packetDemod;
m_magsq = 0.0;
m_sampleBuffer.resize(m_sampleBufferSize);

View File

@ -39,7 +39,7 @@ class ScopeVis;
class RttyDemodSink : public ChannelSampleSink {
public:
RttyDemodSink(RttyDemod *packetDemod);
RttyDemodSink();
~RttyDemodSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -153,7 +153,7 @@ void FreqScanner::start()
qDebug("FreqScanner::start");
m_thread = new QThread();
m_basebandSink = new FreqScannerBaseband(this);
m_basebandSink = new FreqScannerBaseband();
m_basebandSink->setFifoLabel(QString("%1 [%2:%3]")
.arg(m_channelId)
.arg(m_deviceAPI->getDeviceSetIndex())

View File

@ -27,9 +27,7 @@
MESSAGE_CLASS_DEFINITION(FreqScannerBaseband::MsgConfigureFreqScannerBaseband, Message)
FreqScannerBaseband::FreqScannerBaseband(FreqScanner *freqScanner) :
m_freqScanner(freqScanner),
m_sink(freqScanner),
FreqScannerBaseband::FreqScannerBaseband() :
m_messageQueueToGUI(nullptr)
{
qDebug("FreqScannerBaseband::FreqScannerBaseband");

View File

@ -63,7 +63,7 @@ public:
{ }
};
FreqScannerBaseband(FreqScanner *freqScanner);
FreqScannerBaseband();
~FreqScannerBaseband();
void reset();
void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -26,7 +26,7 @@
#include "freqscanner.h"
#include "freqscannersink.h"
FreqScannerSink::FreqScannerSink(FreqScanner *ilsDemod) :
FreqScannerSink::FreqScannerSink() :
m_channel(nullptr),
m_channelSampleRate(48000),
m_channelFrequencyOffset(0),
@ -40,7 +40,6 @@ FreqScannerSink::FreqScannerSink(FreqScanner *ilsDemod) :
m_binsPerChannel(16),
m_averageCount(0)
{
(void)ilsDemod;
applySettings(m_settings, QStringList(), true);
applyChannelSettings(m_channelSampleRate, m_channelFrequencyOffset, 16, 4, true);

View File

@ -37,7 +37,7 @@ class FreqScanner;
class FreqScannerSink : public ChannelSampleSink {
public:
FreqScannerSink(FreqScanner *packetDemod);
FreqScannerSink();
~FreqScannerSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -46,7 +46,7 @@ HeatMap::HeatMap(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new HeatMapBaseband(this);
m_basebandSink = new HeatMapBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -26,8 +26,7 @@
MESSAGE_CLASS_DEFINITION(HeatMapBaseband::MsgConfigureHeatMapBaseband, Message)
HeatMapBaseband::HeatMapBaseband(HeatMap *heatDemod) :
m_sink(heatDemod),
HeatMapBaseband::HeatMapBaseband() :
m_running(false)
{
qDebug("HeatMapBaseband::HeatMapBaseband");

View File

@ -62,7 +62,7 @@ public:
{ }
};
HeatMapBaseband(HeatMap *heatDemod);
HeatMapBaseband();
~HeatMapBaseband();
void reset();
void startWork();

View File

@ -24,7 +24,7 @@
#include "heatmap.h"
#include "heatmapsink.h"
HeatMapSink::HeatMapSink(HeatMap *heatMap) :
HeatMapSink::HeatMapSink() :
m_scopeSink(nullptr),
m_channelSampleRate(10000),
m_channelFrequencyOffset(0),
@ -36,8 +36,6 @@ HeatMapSink::HeatMapSink(HeatMap *heatMap) :
m_sampleBufferSize(1000),
m_sampleBufferIndex(0)
{
(void)heatMap;
resetMagLevels();
m_sampleBuffer.resize(m_sampleBufferSize);

View File

@ -41,7 +41,7 @@ class ScopeVis;
class HeatMapSink : public ChannelSampleSink {
public:
HeatMapSink(HeatMap *heatMap);
HeatMapSink();
~HeatMapSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -53,7 +53,7 @@ void LocalSinkSettings::resetToDefaults()
m_reverseAPIChannelIndex = 0;
m_workspaceIndex = 0;
m_hidden = false;
m_maxFFTBands = 32;
m_maxFFTBands = 20;
}
QByteArray LocalSinkSettings::serialize() const

View File

@ -62,7 +62,7 @@ NoiseFigure::NoiseFigure(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new NoiseFigureBaseband(this);
m_basebandSink = new NoiseFigureBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -26,8 +26,7 @@
MESSAGE_CLASS_DEFINITION(NoiseFigureBaseband::MsgConfigureNoiseFigureBaseband, Message)
NoiseFigureBaseband::NoiseFigureBaseband(NoiseFigure *aisDemod) :
m_sink(aisDemod),
NoiseFigureBaseband::NoiseFigureBaseband() :
m_running(false)
{
qDebug("NoiseFigureBaseband::NoiseFigureBaseband");

View File

@ -60,7 +60,7 @@ public:
{ }
};
NoiseFigureBaseband(NoiseFigure *aisDemod);
NoiseFigureBaseband();
~NoiseFigureBaseband();
void reset();
void startWork();

View File

@ -25,7 +25,7 @@
#include "noisefigure.h"
#include "noisefiguresink.h"
NoiseFigureSink::NoiseFigureSink(NoiseFigure *noiseFigure) :
NoiseFigureSink::NoiseFigureSink() :
m_channelSampleRate(48000),
m_fftSequence(-1),
m_fft(nullptr),
@ -38,8 +38,6 @@ NoiseFigureSink::NoiseFigureSink(NoiseFigure *noiseFigure) :
m_count(0),
m_enabled(false)
{
(void)noiseFigure;
m_magsq = 0.0;
applySettings(m_settings, true);

View File

@ -38,7 +38,7 @@ class NoiseFigure;
class NoiseFigureSink : public ChannelSampleSink {
public:
NoiseFigureSink(NoiseFigure *aisDemod);
NoiseFigureSink();
~NoiseFigureSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -51,7 +51,7 @@ RadioClock::RadioClock(DeviceAPI *deviceAPI) :
{
setObjectName(m_channelId);
m_basebandSink = new RadioClockBaseband(this);
m_basebandSink = new RadioClockBaseband();
m_basebandSink->setMessageQueueToChannel(getInputMessageQueue());
m_basebandSink->setChannel(this);
m_basebandSink->moveToThread(&m_thread);

View File

@ -27,8 +27,7 @@
MESSAGE_CLASS_DEFINITION(RadioClockBaseband::MsgConfigureRadioClockBaseband, Message)
RadioClockBaseband::RadioClockBaseband(RadioClock *radioClock) :
m_sink(radioClock),
RadioClockBaseband::RadioClockBaseband() :
m_running(false)
{
qDebug("RadioClockBaseband::RadioClockBaseband");

View File

@ -62,7 +62,7 @@ public:
{ }
};
RadioClockBaseband(RadioClock *radioClock);
RadioClockBaseband();
~RadioClockBaseband();
void reset();
void startWork();

View File

@ -26,7 +26,7 @@
#include "radioclock.h"
#include "radioclocksink.h"
RadioClockSink::RadioClockSink(RadioClock *radioClock) :
RadioClockSink::RadioClockSink() :
m_scopeSink(nullptr),
m_channelSampleRate(RadioClockSettings::RADIOCLOCK_CHANNEL_SAMPLE_RATE),
m_channelFrequencyOffset(0),
@ -47,9 +47,7 @@ RadioClockSink::RadioClockSink(RadioClock *radioClock) :
m_zeroCount(0),
m_sampleBufferIndex(0),
m_gotMarker(false)
{
(void)radioClock;
{
m_phaseDiscri.setFMScaling(RadioClockSettings::RADIOCLOCK_CHANNEL_SAMPLE_RATE / (2.0f * 20.0/M_PI));
applySettings(m_settings, true);
applyChannelSettings(m_channelSampleRate, m_channelFrequencyOffset, true);

View File

@ -42,7 +42,7 @@ class ScopeVis;
class RadioClockSink : public ChannelSampleSink {
public:
RadioClockSink(RadioClock *radioClock);
RadioClockSink();
~RadioClockSink();
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end);

View File

@ -892,7 +892,7 @@ void WDSPRx::sendChannelSettings(
const WDSPRxSettings& settings,
bool force)
{
qDebug("WDSPRx::sendChannelSettings: %d pipes", pipes.size());
qDebug("WDSPRx::sendChannelSettings: %d pipes", (int)pipes.size());
for (const auto& pipe : pipes)
{

View File

@ -21,9 +21,7 @@
#if defined(ANDROID)
#include <QOpenGLFunctions_ES2>
#else
#include <QOpenGLFunctions_2_0>
#include <QOpenGLFunctions_2_1>
#include <QOpenGLFunctions_3_0>
#include <QOpenGLFunctions_3_3_Core>
#endif
#include <QOpenGLContext>
#include <QtOpenGL>