forked from vshokorov/asteroid
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscene3d.h
48 lines (38 loc) · 974 Bytes
/
scene3d.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef SCENE3D_H
#define SCENE3D_H
#include <QGLWidget>
class Scene3D : public QGLWidget
{
private:
GLfloat xRot;
GLfloat yRot;
GLfloat zRot;
GLfloat zTra;
GLfloat nSca;
//std::ifstream file;
QPoint ptrMousePosition;
void scale_plus();
void scale_minus();
void rotate_up();
void rotate_down();
void rotate_left();
void rotate_right();
void translate_down();
void translate_up();
void defaultScene();
void drawAxis();
void my_getArrays();
void drawFigure();
protected:
void initializeGL();
void resizeGL(int nWidth, int nHeight);
void paintGL();
void mousePressEvent(QMouseEvent* pe);
void mouseMoveEvent(QMouseEvent* pe);
void mouseReleaseEvent(QMouseEvent* pe);
void wheelEvent(QWheelEvent* pe);
void keyPressEvent(QKeyEvent* pe);
public:
Scene3D(QWidget* parent = 0);
};
#endif