2014-05-18 11:52:39 -04:00
|
|
|
#ifndef INCLUDE_GLSPECTRUMGUI_H
|
|
|
|
#define INCLUDE_GLSPECTRUMGUI_H
|
|
|
|
|
|
|
|
#include <QWidget>
|
|
|
|
#include "dsp/dsptypes.h"
|
|
|
|
#include "util/export.h"
|
2017-10-01 11:54:48 -04:00
|
|
|
#include "settings/serializable.h"
|
2014-05-18 11:52:39 -04:00
|
|
|
|
|
|
|
namespace Ui {
|
|
|
|
class GLSpectrumGUI;
|
|
|
|
}
|
|
|
|
|
|
|
|
class MessageQueue;
|
|
|
|
class SpectrumVis;
|
|
|
|
class GLSpectrum;
|
|
|
|
|
2018-03-03 14:23:38 -05:00
|
|
|
class SDRGUI_API GLSpectrumGUI : public QWidget, public Serializable {
|
2014-05-18 11:52:39 -04:00
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
|
|
|
explicit GLSpectrumGUI(QWidget* parent = NULL);
|
|
|
|
~GLSpectrumGUI();
|
|
|
|
|
|
|
|
void setBuddies(MessageQueue* messageQueue, SpectrumVis* spectrumVis, GLSpectrum* glSpectrum);
|
|
|
|
|
|
|
|
void resetToDefaults();
|
2017-10-01 11:54:48 -04:00
|
|
|
virtual QByteArray serialize() const;
|
|
|
|
virtual bool deserialize(const QByteArray& data);
|
2014-05-18 11:52:39 -04:00
|
|
|
|
|
|
|
private:
|
|
|
|
Ui::GLSpectrumGUI* ui;
|
|
|
|
|
|
|
|
MessageQueue* m_messageQueue;
|
|
|
|
SpectrumVis* m_spectrumVis;
|
|
|
|
GLSpectrum* m_glSpectrum;
|
|
|
|
|
|
|
|
qint32 m_fftSize;
|
|
|
|
qint32 m_fftOverlap;
|
|
|
|
qint32 m_fftWindow;
|
|
|
|
Real m_refLevel;
|
|
|
|
Real m_powerRange;
|
|
|
|
int m_decay;
|
2015-07-15 02:48:02 -04:00
|
|
|
int m_histogramLateHoldoff;
|
|
|
|
int m_histogramStroke;
|
2015-05-12 09:49:03 -04:00
|
|
|
int m_displayGridIntensity;
|
2015-07-18 11:53:57 -04:00
|
|
|
int m_displayTraceIntensity;
|
2014-05-18 11:52:39 -04:00
|
|
|
bool m_displayWaterfall;
|
|
|
|
bool m_invertedWaterfall;
|
|
|
|
bool m_displayMaxHold;
|
2015-07-15 22:55:14 -04:00
|
|
|
bool m_displayCurrent;
|
2014-05-18 11:52:39 -04:00
|
|
|
bool m_displayHistogram;
|
|
|
|
bool m_displayGrid;
|
|
|
|
bool m_invert;
|
|
|
|
|
|
|
|
void applySettings();
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
void on_fftWindow_currentIndexChanged(int index);
|
|
|
|
void on_fftSize_currentIndexChanged(int index);
|
|
|
|
void on_refLevel_currentIndexChanged(int index);
|
|
|
|
void on_levelRange_currentIndexChanged(int index);
|
2015-07-15 02:48:02 -04:00
|
|
|
void on_decay_valueChanged(int index);
|
|
|
|
void on_holdoff_valueChanged(int index);
|
|
|
|
void on_stroke_valueChanged(int index);
|
2015-05-12 09:49:03 -04:00
|
|
|
void on_gridIntensity_valueChanged(int index);
|
2015-07-18 11:53:57 -04:00
|
|
|
void on_traceIntensity_valueChanged(int index);
|
2014-05-18 11:52:39 -04:00
|
|
|
|
|
|
|
void on_waterfall_toggled(bool checked);
|
|
|
|
void on_histogram_toggled(bool checked);
|
|
|
|
void on_maxHold_toggled(bool checked);
|
2015-07-15 22:55:14 -04:00
|
|
|
void on_current_toggled(bool checked);
|
2014-05-18 11:52:39 -04:00
|
|
|
void on_invert_toggled(bool checked);
|
|
|
|
void on_grid_toggled(bool checked);
|
2015-07-23 19:09:03 -04:00
|
|
|
void on_clearSpectrum_clicked(bool checked);
|
2014-05-18 11:52:39 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // INCLUDE_GLSPECTRUMGUI_H
|