]> Shamusworld >> Repos - virtualjaguar/blob - src/gui/glwidget.h
Fixed fullscreen mode, shrunk screen width.
[virtualjaguar] / src / gui / glwidget.h
1 // Implementation of OpenGL widget using Qt
2 //
3 // by James Hammons
4 // (C) 2010 Underground Software
5
6 #ifndef __GLWIDGET_H__
7 #define __GLWIDGET_H__
8
9 #include <QtGui>
10 #include <QGLWidget>
11
12 class GLWidget: public QGLWidget
13 {
14         Q_OBJECT
15
16         public:
17                 GLWidget(QWidget * parent = 0);
18                 ~GLWidget();
19
20 //              QSize minimumSizeHint() const;
21 //              QSize sizeHint() const;
22
23 //      signals:
24 //              void clicked();
25
26         protected:
27                 void initializeGL();
28                 void paintGL();
29                 void resizeGL(int width, int height);
30
31 //      private:
32         public:
33                 GLuint texture;
34                 int textureWidth, textureHeight;
35
36                 uint32_t * buffer;
37                 unsigned rasterWidth, rasterHeight;
38
39                 bool synchronize;
40                 unsigned filter;
41                 int offset;
42                 bool fullscreen;
43                 int outputWidth;
44 };
45
46 #endif  // __GLWIDGET_H__