1 #ifndef WATERFALL_DISPLAY_PLOT_HPP
2 #define WATERFALL_DISPLAY_PLOT_HPP
5 #include <qwt_plot_zoomer.h>
6 #include <qwt_plot_panner.h>
8 #include <plot_waterfall.h>
10 #include <highResTimeFunctions.h>
12 class WaterfallDisplayPlot:public QwtPlot{
16 WaterfallDisplayPlot(QWidget*);
17 virtual ~WaterfallDisplayPlot();
21 void SetFrequencyRange(const double, const double,
22 const double, const bool,
23 const double units=1000.0,
24 const std::string &strunits = "kHz");
25 double GetStartFrequency()const;
26 double GetStopFrequency()const;
28 void PlotNewData(const double* dataPoints, const int64_t numDataPoints,
29 const double timePerFFT, const timespec timestamp,
30 const int droppedFrames);
32 void SetIntensityRange(const double minIntensity, const double maxIntensity);
34 virtual void replot(void);
36 int GetIntensityColorMapType()const;
37 void SetIntensityColorMapType( const int, const QColor, const QColor );
38 const QColor GetUserDefinedLowIntensityColor()const;
39 const QColor GetUserDefinedHighIntensityColor()const;
41 static const int INTENSITY_COLOR_MAP_TYPE_MULTI_COLOR = 0;
42 static const int INTENSITY_COLOR_MAP_TYPE_WHITE_HOT = 1;
43 static const int INTENSITY_COLOR_MAP_TYPE_BLACK_HOT = 2;
44 static const int INTENSITY_COLOR_MAP_TYPE_INCANDESCENT = 3;
45 static const int INTENSITY_COLOR_MAP_TYPE_USER_DEFINED = 4;
48 void UpdatedLowerIntensityLevel(const double);
49 void UpdatedUpperIntensityLevel(const double);
54 void _UpdateIntensityRangeDisplay();
56 double _startFrequency;
57 double _stopFrequency;
59 PlotWaterfall *d_spectrogram;
61 QwtPlotPanner* _panner;
62 QwtPlotZoomer* _zoomer;
64 WaterfallData* _waterfallData;
70 double _displayIntervalTime;
72 int _intensityColorMapType;
73 QColor _userDefinedLowIntensityColor;
74 QColor _userDefinedHighIntensityColor;
77 #endif /* WATERFALL_DISPLAY_PLOT_HPP */