#ifndef __QTGLVIEWER_H #define __QTGLVIEWER_H #ifdef USE_QT #include namespace GtpVisibilityPreprocessor { class QtGlRendererWidget; class QtGlViewer : public QGLWidget { //Q_OBJECT friend class QtGlRendererWidget; friend class GlRenderer; public: QtGlRendererWidget *mRenderer; QtGlViewer(QWidget *parent, QtGlRendererWidget *renderer); virtual ~QtGlViewer(){}; QSize minimumSizeHint() const; QSize sizeHint() const; // This method has to be rendefined by all renderer implementations virtual void RenderScene(); protected: void initializeGL(); void paintGL(); void resizeGL(int width, int height); void mousePressEvent(QMouseEvent *event); void mouseMoveEvent(QMouseEvent *event); void keyPressEvent ( QKeyEvent * e ); bool mWireframe; private: float manipulatorLastQuat[4]; float scale; QPoint lastPos; }; } #endif #endif