Changeset 4334 in ntrip for trunk/BNC/src/rinex/polarplot.h
- Timestamp:
- Jun 24, 2012, 10:34:29 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/rinex/polarplot.h
r4331 r4334 20 20 // 21 21 ////////////////////////////////////////////////////////////////////////////// 22 class t_polarPoint { 23 public: 24 t_polarPoint(double az, double zen, double value) { 25 _az = az; 26 _zen = zen; 27 _value = value; 28 } 29 double _az; 30 double _zen; 31 double _value; 32 }; 33 34 // 35 ////////////////////////////////////////////////////////////////////////////// 22 36 class t_polarData: public QwtSeriesData<QwtPointPolar> { 23 37 public: 24 t_polarData(size_t size) { 25 _size = size; 38 t_polarData(QVector<t_polarPoint*>* data) { 39 _data = data; 40 _size = data->size(); 26 41 } 27 virtual QwtPointPolar sample(size_t ii) const; 42 ~t_polarData() { 43 for (int ii = 0; ii < _data->size(); ii++) { 44 delete _data->at(ii); 45 } 46 } 47 virtual QwtPointPolar sample(size_t ii) const { 48 const t_polarPoint* point = _data->at(ii); 49 QwtPointPolar qp(point->_az, point->_zen); qp._value = point->_value; 50 return qp; 51 } 28 52 virtual size_t size() const {return _size;} 29 virtual QRectF boundingRect() const { 30 return d_boundingRect; 31 } 53 virtual QRectF boundingRect() const {return d_boundingRect;} 32 54 protected: 33 55 size_t _size; 56 private: 57 QVector<t_polarPoint*>* _data; 34 58 }; 35 59 … … 41 65 public: 42 66 t_polarPlot(QWidget* = 0); 67 void addCurve(QVector<t_polarPoint*>* data); 43 68 44 69 private: 45 t_polarCurve* createCurve() const;46 70 }; 47 71
Note:
See TracChangeset
for help on using the changeset viewer.