source: trunk/geant4/OpenGLQT_exemple/src/glwidget.h@ 688

Last change on this file since 688 was 561, checked in by garnier, 18 years ago

r563@mac-90108: laurentgarnier | 2007-08-14 12:28:16 +0200
mise a jour suite au plantage de svk (cheksum error) suite au crash du DD en juin

File size: 1.2 KB
RevLine 
[548]1#ifndef GLWIDGET_H
2#define GLWIDGET_H
[546]3
[548]4#include <QGLWidget>
[546]5
6 class GLWidget : public QGLWidget
7 {
[548]8/* Q_OBJECT */
[546]9
10 public:
11 GLWidget(QWidget *parent = 0);
12 ~GLWidget();
[561]13 void initializeGL();
14 void initialize();
15 void resizeGL(int width, int height);
16 void paintGL();
[546]17
[561]18/* QSize minimumSizeHint() const; */
19/* QSize sizeHint() const; */
[546]20
[561]21 protected:
22 void setXRotation(int angle);
23 void setYRotation(int angle);
24 void setZRotation(int angle);
[546]25
[548]26/* signals: */
27/* void xRotationChanged(int angle); */
28/* void yRotationChanged(int angle); */
29/* void zRotationChanged(int angle); */
[546]30
[561]31 void mousePressEvent(QMouseEvent*);
32 void mouseMoveEvent(QMouseEvent*);
33 void normalizeAngle(int *angle);
[546]34
35 private:
36 GLuint makeObject();
37 void quad(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2,
38 GLdouble x3, GLdouble y3, GLdouble x4, GLdouble y4);
39 void extrude(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
40
41 GLuint object;
42 int xRot;
43 int yRot;
44 int zRot;
[561]45 float reelXRot;
46 float realYRot;
47 float realZRot;
[546]48 QPoint lastPos;
49 QColor trolltechGreen;
50 QColor trolltechPurple;
51 };
52
53 #endif
Note: See TracBrowser for help on using the repository browser.