Qwt User's Guide 6.3.0

Loading...
Searching...
No Matches
qwt_polar_spectrogram.h
1/******************************************************************************
2 * QwtPolar Widget Library
3 * Copyright (C) 2008 Uwe Rathmann
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the Qwt License, Version 1.0
7 *****************************************************************************/
8
9#ifndef QWT_POLAR_SPECTROGRAM_H
10#define QWT_POLAR_SPECTROGRAM_H
11
12#include "qwt_global.h"
13#include "qwt_polar_item.h"
14#include <qimage.h>
15
16 class QwtRasterData;
17 class QwtColorMap;
18
28 class QWT_EXPORT QwtPolarSpectrogram : public QwtPolarItem
29{
30 public:
37 enum PaintAttribute
38 {
44 ApproximatedAtan = 0x01
45 };
46
47 Q_DECLARE_FLAGS( PaintAttributes, PaintAttribute )
48
49 explicit QwtPolarSpectrogram();
50 virtual ~QwtPolarSpectrogram();
51
52 void setData( QwtRasterData* data );
53 const QwtRasterData* data() const;
54
55 void setColorMap( QwtColorMap* );
56 const QwtColorMap* colorMap() const;
57
58 void setPaintAttribute( PaintAttribute, bool on = true );
59 bool testPaintAttribute( PaintAttribute ) const;
60
61 virtual int rtti() const QWT_OVERRIDE;
62
63 virtual void draw( QPainter* painter,
64 const QwtScaleMap& azimuthMap, const QwtScaleMap& radialMap,
65 const QPointF& pole, double radius,
66 const QRectF& canvasRect ) const QWT_OVERRIDE;
67
68 virtual QwtInterval boundingInterval( int scaleId ) const QWT_OVERRIDE;
69
70 protected:
71 virtual QImage renderImage(
72 const QwtScaleMap& azimuthMap, const QwtScaleMap& radialMap,
73 const QPointF& pole, const QRect& rect ) const;
74
75 virtual void renderTile(
76 const QwtScaleMap& azimuthMap, const QwtScaleMap& radialMap,
77 const QPointF& pole, const QPoint& imagePos,
78 const QRect& tile, QImage* image ) const;
79
80 private:
81 class TileInfo;
82 void renderTileInfo( const QwtScaleMap&, const QwtScaleMap&,
83 const QPointF& pole, TileInfo* ) const;
84
85 class PrivateData;
86 PrivateData* m_data;
87};
88
89Q_DECLARE_OPERATORS_FOR_FLAGS( QwtPolarSpectrogram::PaintAttributes )
90
91#endif
QwtColorMap
QwtColorMap is used to map values into colors.
Definition qwt_color_map.h:38
QwtInterval
A class representing an interval.
Definition qwt_interval.h:23
QwtPolarItem
Base class for items on a polar plot.
Definition qwt_polar_item.h:38
QwtPolarItem::rtti
virtual int rtti() const
Definition qwt_polar_item.cpp:112
QwtPolarSpectrogram
An item, which displays a spectrogram.
Definition qwt_polar_spectrogram.h:29
QwtPolarSpectrogram::PaintAttribute
PaintAttribute
Definition qwt_polar_spectrogram.h:38
QwtPolarSpectrogram::PaintAttributes
QFlags< PaintAttribute > PaintAttributes
Definition qwt_polar_spectrogram.h:47
QwtRasterData
QwtRasterData defines an interface to any type of raster data.
Definition qwt_raster_data.h:43
QwtScaleMap
A scale map.
Definition qwt_scale_map.h:27