Revision 1943,
958 bytes
checked in by bittner, 18 years ago
(diff) |
functional merge
|
Line | |
---|
1 | #ifndef __QTGLVIEWER_H
|
---|
2 | #define __QTGLVIEWER_H
|
---|
3 |
|
---|
4 | #ifdef USE_QT
|
---|
5 | #include <QtOpenGL>
|
---|
6 |
|
---|
7 |
|
---|
8 | namespace GtpVisibilityPreprocessor {
|
---|
9 |
|
---|
10 | class QtGlRendererWidget;
|
---|
11 |
|
---|
12 | class QtGlViewer : public QGLWidget
|
---|
13 | {
|
---|
14 | Q_OBJECT
|
---|
15 |
|
---|
16 | friend class QtGlRendererWidget;
|
---|
17 | friend class GlRenderer;
|
---|
18 |
|
---|
19 | public:
|
---|
20 | QtGlRendererWidget *mRenderer;
|
---|
21 |
|
---|
22 | QtGlViewer(QWidget *parent,
|
---|
23 | QtGlRendererWidget *renderer);
|
---|
24 |
|
---|
25 | virtual ~QtGlViewer(){};
|
---|
26 |
|
---|
27 | QSize minimumSizeHint() const;
|
---|
28 | QSize sizeHint() const;
|
---|
29 |
|
---|
30 | // This method has to be rendefined by all renderer implementations
|
---|
31 | virtual void RenderScene();
|
---|
32 |
|
---|
33 | protected:
|
---|
34 | void initializeGL();
|
---|
35 | void paintGL();
|
---|
36 | void resizeGL(int width, int height);
|
---|
37 | void mousePressEvent(QMouseEvent *event);
|
---|
38 | void mouseMoveEvent(QMouseEvent *event);
|
---|
39 |
|
---|
40 | void keyPressEvent ( QKeyEvent * e );
|
---|
41 |
|
---|
42 | bool mWireframe;
|
---|
43 |
|
---|
44 | private:
|
---|
45 |
|
---|
46 | float manipulatorLastQuat[4];
|
---|
47 | float scale;
|
---|
48 | QPoint lastPos;
|
---|
49 |
|
---|
50 | };
|
---|
51 |
|
---|
52 | }
|
---|
53 |
|
---|
54 | #endif
|
---|
55 | #endif
|
---|
Note: See
TracBrowser
for help on using the repository browser.