source: trunk/FACT++/gui/QCameraWidget.h@ 12071

Last change on this file since 12071 was 12054, checked in by tbretz, 13 years ago
Removed a global namespace definition from the header file.
File size: 1.4 KB
Line 
1#ifndef Q_CAMERA_WIDGET_H_
2#define Q_CAMERA_WIDGET_H_
3
4#include "BasicGlCamera.h"
5#include <valarray>
6#include <set>
7
8class QCameraWidget : public BasicGlCamera
9{
10 Q_OBJECT
11
12 typedef std::pair<double, double> Position;
13 typedef std::vector<Position> Positions;
14
15 //FIXME this variable seems to be deprecated
16 Positions fGeom;
17
18 std::vector<bool> fBold;
19 std::vector<bool> fEnable;
20
21 std::vector<int> highlightedPatches;
22 std::vector<int> highlightedPixels;
23
24
25 int lastFace;
26
27
28public:
29 void highlightPixel(int idx, bool highlight=true);
30 void highlightPatch(int idx, bool highlight=true);
31 void clearHighlightedPatches();
32 void clearHighlightedPixels();
33 QCameraWidget(QWidget *pparent = 0);
34 void paintGL();
35 void mousePressEvent(QMouseEvent *cEvent);
36 void mouseMoveEvent(QMouseEvent *event);
37 void mouseDoubleClickEvent(QMouseEvent *event);
38 void Reset();
39 void drawCamera(bool alsoWire);
40 void DrawCameraText();
41 void drawPatches();
42 void SetEnable(int idx, bool b);
43 double GetData(int idx);
44 const char *GetName();
45
46 int GetIdx(float px, float py);
47 char *GetObjectInfo(int px, int py);
48
49 void SetData(const std::valarray<double> &ddata);
50 void SetData(const std::valarray<float> &ddata);
51
52
53private:
54 void CalculatePixelsColor();
55 void CalculatePatchColor();
56
57};
58
59typedef QCameraWidget Camera;
60#endif
Note: See TracBrowser for help on using the repository browser.