1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 01:55:48 -05:00

SpectrumVis: removed message queue parameter from configure method

This commit is contained in:
f4exb 2020-05-01 02:23:26 +02:00
parent 79b670d919
commit 7d6d351891
6 changed files with 58 additions and 55 deletions

View File

@ -397,15 +397,15 @@ BFMDemodGUI::BFMDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseban
ui->glSpectrum->setDisplayMaxHold(false);
ui->glSpectrum->setSsbSpectrum(true);
m_spectrumVis->configure(
m_spectrumVis->getInputMessageQueue(),
64, // FFT size
0, // Ref level (dB)
100, // Power range (dB)
10, // overlapping %
0, // number of averaging samples
SpectrumVis::AvgModeNone, // no averaging
FFTWindow::BlackmanHarris,
false); // logarithmic scale
64, // FFT size
0, // Ref level (dB)
100, // Power range (dB)
10, // overlapping %
0, // number of averaging samples
SpectrumVis::AvgModeNone, // no averaging
FFTWindow::BlackmanHarris,
false // logarithmic scale
);
connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick()));
m_channelMarker.blockSignals(true);

View File

@ -187,15 +187,16 @@ UDPSinkGUI::UDPSinkGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandS
ui->glSpectrum->setSampleRate(ui->sampleRate->text().toInt());
ui->glSpectrum->setDisplayWaterfall(true);
ui->glSpectrum->setDisplayMaxHold(true);
m_spectrumVis->configure(m_spectrumVis->getInputMessageQueue(),
64, // FFT size
0, // Ref level (dB)
100, // Power range (dB)
10, // overlapping %
0, // number of averaging samples
SpectrumVis::AvgModeNone, // no averaging
FFTWindow::BlackmanHarris,
false); // logarithmic scale
m_spectrumVis->configure(
64, // FFT size
0, // Ref level (dB)
100, // Power range (dB)
10, // overlapping %
0, // number of averaging samples
SpectrumVis::AvgModeNone, // no averaging
FFTWindow::BlackmanHarris,
false // logarithmic scale
);
ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer());
connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick()));

View File

@ -144,15 +144,16 @@ UDPSourceGUI::UDPSourceGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb
ui->glSpectrum->setSampleRate(ui->sampleRate->text().toInt());
ui->glSpectrum->setDisplayWaterfall(true);
ui->glSpectrum->setDisplayMaxHold(true);
m_spectrumVis->configure(m_spectrumVis->getInputMessageQueue(),
64, // FFT size
0, // Ref level (dB)
100, // Power range (dB)
10, // overlapping %
0, // number of averaging samples
SpectrumVis::AvgModeNone, // no averaging
FFTWindow::BlackmanHarris,
false); // logarithmic scale
m_spectrumVis->configure(
64, // FFT size
0, // Ref level (dB)
100, // Power range (dB)
10, // overlapping %
0, // number of averaging samples
SpectrumVis::AvgModeNone, // no averaging
FFTWindow::BlackmanHarris,
false // logarithmic scale
);
ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer());
connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick()));

View File

@ -81,15 +81,15 @@ void SpectrumVis::closeWSSpectrum()
getInputMessageQueue()->push(cmd);
}
void SpectrumVis::configure(MessageQueue* msgQueue,
int fftSize,
float refLevel,
float powerRange,
int overlapPercent,
unsigned int averagingNb,
AvgMode averagingMode,
FFTWindow::Function window,
bool linear)
void SpectrumVis::configure(
int fftSize,
float refLevel,
float powerRange,
int overlapPercent,
unsigned int averagingNb,
AvgMode averagingMode,
FFTWindow::Function window,
bool linear)
{
GLSpectrumSettings settings = m_settings;
settings.m_fftSize = fftSize;
@ -103,7 +103,7 @@ void SpectrumVis::configure(MessageQueue* msgQueue,
MsgConfigureSpectrumVis* cmd = MsgConfigureSpectrumVis::create(settings, false);
msgQueue->push(cmd);
getInputMessageQueue()->push(cmd);
}
void SpectrumVis::setScalef(Real scalef)

View File

@ -78,15 +78,16 @@ public:
void openWSSpectrum();
void closeWSSpectrum();
void configure(MessageQueue* msgQueue,
int fftSize,
float refLevel,
float powerRange,
int overlapPercent,
unsigned int averagingNb,
AvgMode averagingMode,
FFTWindow::Function window,
bool m_linear);
void configure(
int fftSize,
float refLevel,
float powerRange,
int overlapPercent,
unsigned int averagingNb,
AvgMode averagingMode,
FFTWindow::Function window,
bool m_linear
);
void setScalef(Real scalef);
void configureWSSpectrum(const QString& address, uint16_t port);

View File

@ -229,15 +229,15 @@ void GLSpectrumGUI::applySettingsVis()
if (m_spectrumVis)
{
m_spectrumVis->configure(m_messageQueueToVis,
m_fftSize,
m_refLevel,
m_powerRange,
m_fftOverlap,
m_averagingNb,
(SpectrumVis::AvgMode) m_averagingMode,
(FFTWindow::Function) m_fftWindow,
m_linear
m_spectrumVis->configure(
m_fftSize,
m_refLevel,
m_powerRange,
m_fftOverlap,
m_averagingNb,
(SpectrumVis::AvgMode) m_averagingMode,
(FFTWindow::Function) m_fftWindow,
m_linear
);
}