GNU Radio 3.4.0 C++ API
|
00001 #ifndef PLOT_WATERFALL_H 00002 #define PLOT_WATERFALL_H 00003 00004 #include <qglobal.h> 00005 #include <waterfallGlobalData.h> 00006 00007 #include "qwt_valuelist.h" 00008 #include "qwt_plot_rasteritem.h" 00009 00010 class QwtColorMap; 00011 00012 /*! 00013 \brief A plot item, which displays a waterfall spectrogram 00014 00015 A waterfall displays threedimenional data, where the 3rd dimension 00016 ( the intensity ) is displayed using colors. The colors are calculated 00017 from the values using a color map. 00018 00019 \sa QwtRasterData, QwtColorMap 00020 */ 00021 00022 class PlotWaterfall: public QwtPlotRasterItem 00023 { 00024 public: 00025 explicit PlotWaterfall(WaterfallData* data, const QString &title = QString::null); 00026 virtual ~PlotWaterfall(); 00027 00028 const WaterfallData* data()const; 00029 00030 void setColorMap(const QwtColorMap &); 00031 const QwtColorMap &colorMap() const; 00032 00033 virtual QwtDoubleRect boundingRect() const; 00034 virtual QSize rasterHint(const QwtDoubleRect &) const; 00035 00036 virtual int rtti() const; 00037 00038 virtual void draw(QPainter *p, 00039 const QwtScaleMap &xMap, const QwtScaleMap &yMap, 00040 const QRect &rect) const; 00041 00042 protected: 00043 virtual QImage renderImage( 00044 const QwtScaleMap &xMap, const QwtScaleMap &yMap, 00045 const QwtDoubleRect &rect) const; 00046 00047 private: 00048 class PrivateData; 00049 PrivateData *d_data; 00050 }; 00051 00052 #endif