GNU Radio Manual and C++ API Reference 3.9.4.0
The Free & Open Software Radio Ecosystem
plot_raster.h
Go to the documentation of this file.
1/* -*- c++ -*- */
2/*
3 * Copyright 2012,2013 Free Software Foundation, Inc.
4 *
5 * This file is part of GNU Radio
6 *
7 * SPDX-License-Identifier: GPL-3.0-or-later
8 *
9 */
10
11#ifndef PLOT_TIMERASTER_H
12#define PLOT_TIMERASTER_H
13
15#include <qglobal.h>
16#include <qwt_plot_rasteritem.h>
17
18#if QWT_VERSION >= 0x060000
19#include <qwt_compat.h>
20#include <qwt_point_3d.h> // doesn't seem necessary, but is...
21#endif
22
23class QwtColorMap;
24
25/*!
26 * \brief A plot item, which displays a time raster.
27 * \ingroup qtgui_blk
28 *
29 * \details
30 * A time raster displays three-dimensional data, where the 3rd dimension
31 * (the intensity) is displayed using colors. The colors are calculated
32 * from the values using a color map.
33 *
34 * \sa QwtRasterData, QwtColorMap
35 */
36class PlotTimeRaster : public QwtPlotRasterItem
37{
38public:
39 explicit PlotTimeRaster(const QString& title = QString());
40 ~PlotTimeRaster() override;
41
42 const TimeRasterData* data() const;
43
45
46 void setColorMap(const QwtColorMap* map);
47
48 const QwtColorMap& colorMap() const;
49
50#if QWT_VERSION < 0x060000
51 virtual QwtDoubleRect boundingRect() const;
52 virtual QSize rasterHint(const QwtDoubleRect&) const;
53 virtual QwtDoubleInterval interval(Qt::Axis ax) const;
54#else
55 QwtInterval interval(Qt::Axis ax) const override;
56#endif
57
58 int rtti() const override;
59
60protected:
61#if QWT_VERSION < 0x060000
62 QImage renderImage(const QwtScaleMap& xMap,
63 const QwtScaleMap& yMap,
64 const QwtDoubleRect& rect) const;
65#else
66 QImage renderImage(const QwtScaleMap& xMap,
67 const QwtScaleMap& yMap,
68 const QRectF& rect,
69 const QSize& size = QSize(0, 0)) const override;
70#endif
71
72private:
73 class PrivateData;
74 PrivateData* d_data;
75};
76
77#endif
A plot item, which displays a time raster.
Definition: plot_raster.h:37
void setData(TimeRasterData *data)
void setColorMap(const QwtColorMap *map)
QImage renderImage(const QwtScaleMap &xMap, const QwtScaleMap &yMap, const QwtDoubleRect &rect) const
PlotTimeRaster(const QString &title=QString())
virtual QwtDoubleInterval interval(Qt::Axis ax) const
virtual QSize rasterHint(const QwtDoubleRect &) const
~PlotTimeRaster() override
virtual QwtDoubleRect boundingRect() const
int rtti() const override
const QwtColorMap & colorMap() const
const TimeRasterData * data() const
Definition: timeRasterGlobalData.h:23
PMT_API pmt_t map(pmt_t proc(const pmt_t &), pmt_t list)
Apply proc element-wise to the elements of list and returns a list of the results,...