source: flair-src/trunk/tools/FlairGCS/src/RangeFinderPlot.h

Last change on this file was 444, checked in by Sanahuja Guillaume, 8 days ago

update buffering (gcs part)
seems to work!

File size: 1.4 KB
Line 
1// %flair:license{
2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
4// %flair:license}
5#ifndef RANGEFINDERPLOT_H_INCLUDED
6#define RANGEFINDERPLOT_H_INCLUDED
7
8#include "DataRemote.h"
9#include <stdint.h>
10
11class QwtPlotShapeItem;
12class Layout;
13class QwtPlot;
14class QMouseEvent;
15
16class RangeFinderPlot : public DataRemote {
17  Q_OBJECT
18
19public:
20  RangeFinderPlot(Layout *parent, int row, int col, QString name,
21                  QString x_name, QString y_name, float xmin, float xmax,
22                  float ymin, float ymax, float start_angle, float end_angle,
23                  uint32_t nb_samples, QString data_type, bool invert_axis,
24                  bool enabled, uint16_t period);
25  ~RangeFinderPlot();
26
27protected:
28  void mousePressEvent(QMouseEvent *event);
29
30private:
31  void setYAxisScale(float ymin, float ymax);
32  void setXAxisScale(float xmin, float xmax);
33  void addTriangle(float angle_min, float angle_max);
34  void SetTriangle(uint32_t id, float length);
35  QwtPlot *plot;
36  void XmlEvent(QDomElement *dom);
37  void alignScales(void);
38  float xmin_orig, xmax_orig, ymin_orig, ymax_orig;
39  float start_angle, end_angle;
40  uint32_t nb_samples;
41  QString data_type;
42  QList<QwtPlotShapeItem *> triangles;
43  bool invert_axis;
44
45  bool eventFilter(QObject *, QEvent *);
46  void BufEvent(char **buf, int *buf_size, uint16_t period,uint16_t nb_buffering,bool big_endian);
47};
48
49#endif // RANGEFINDERPLOT_H_INCLUDED
Note: See TracBrowser for help on using the repository browser.