Last change
on this file since 11788 was 11779, checked in by lyard, 13 years ago |
Replaced root camera by openGL camera in the gui
|
File size:
1.2 KB
|
Line | |
---|
1 | #ifndef Q_CAMERA_WIDGET_H_
|
---|
2 | #define Q_CAMERA_WIDGET_H_
|
---|
3 |
|
---|
4 | #include "BasicGlCamera.h"
|
---|
5 | #include <valarray>
|
---|
6 |
|
---|
7 | using namespace std;
|
---|
8 |
|
---|
9 | class QCameraWidget : public BasicGlCamera
|
---|
10 | {
|
---|
11 | Q_OBJECT
|
---|
12 |
|
---|
13 | typedef pair<double, double> Position;
|
---|
14 | typedef vector<Position> Positions;
|
---|
15 |
|
---|
16 | Positions fGeom;
|
---|
17 |
|
---|
18 | vector<bool> fBold;
|
---|
19 | vector<bool> fEnable;
|
---|
20 |
|
---|
21 | int fWhite;
|
---|
22 |
|
---|
23 | int64_t fMin;
|
---|
24 | int64_t fMax;
|
---|
25 |
|
---|
26 | public:
|
---|
27 | QCameraWidget(QWidget *pparent = 0);
|
---|
28 | void paintGL();
|
---|
29 | void mousePressEvent(QMouseEvent *cEvent);
|
---|
30 | void mouseMoveEvent(QMouseEvent *event);
|
---|
31 | void mouseDoubleClickEvent(QMouseEvent *event);
|
---|
32 | void Reset();
|
---|
33 | void drawCamera(bool alsoWire);
|
---|
34 | void SetBold(int idx);
|
---|
35 | void SetWhite(int idx);
|
---|
36 | void SetEnable(int idx, bool b);
|
---|
37 | void Toggle(int idx);
|
---|
38 | double GetData(int idx);
|
---|
39 | void SetMin(int64_t min);
|
---|
40 | void SetMax(int64_t max);
|
---|
41 | const char *GetName();
|
---|
42 |
|
---|
43 | int GetIdx(float px, float py);
|
---|
44 | char *GetObjectInfo(int px, int py);
|
---|
45 |
|
---|
46 | void SetData(const valarray<double> &ddata);
|
---|
47 |
|
---|
48 | Q_SIGNALS:
|
---|
49 | void signalCurrentPixel(int pixel);
|
---|
50 | void signalPixelMoveOver(int pixel);
|
---|
51 | void signalPixelDoubleClick(int pixel);
|
---|
52 |
|
---|
53 | private:
|
---|
54 | void CalculatePixelsColor();
|
---|
55 | };
|
---|
56 |
|
---|
57 | typedef QCameraWidget Camera;
|
---|
58 | #endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.