rock_widget_collection  0.1
SonarView.h
Go to the documentation of this file.
1 /*
2  * File: SonarViewGL.cc
3  * Author: Matthias Goldhoorn (matthias.goldhoorn@dfki.de)
4  *
5  */
6 
7 #ifndef SONARVIEW_H
8 #define SONARVIEW_H
9 
11 
12 class QDESIGNER_WIDGET_EXPORT SonarView : public ImageViewOld
13 {
14  Q_OBJECT
15  Q_CLASSINFO("Author", "Matthias Goldhoorn")
16 
17 public:
18  SonarView(QWidget *parent = NULL,bool use_openGL = true);
19  virtual ~SonarView();
20 
21 public slots:
22  void setOpenGL(bool flag);
23  void setSonarScan(const char *data, int size, double angle,double timeBetweenBins ,bool fromBearing=false);
24  void setPosition(double posX, double posY, double sigmaX, double sigmaY);
25  void setOrientation(const double orientation);
26  void setDistance(double distance, double angle);
27  void paintLine(double bearing, const uint8_t *data, size_t len);
28  void paintReference(double bearing, int distance);
29  void paintPos(int posX, int posY, int sizeX=10, int sizeY=10);
30 
31 protected:
32  void paintEvent(QPaintEvent *event);
33  double lastScale;
35  void keyPressEvent(QKeyEvent*);
36  QImage img;
37 };
38 #endif
39 
int lastBearing
Definition: SonarView.h:34
double lastScale
Definition: SonarView.h:33
virtual void paintEvent(QPaintEvent *event)
QImage img
Definition: SonarView.h:36