-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy paththreadmil.h
68 lines (59 loc) · 1.73 KB
/
threadmil.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#ifndef THREADMIL_H_
#define THREADMIL_H_
#include <osg/Geode>
#include <osg/MatrixTransform>
#include <osg/ShapeDrawable>
#include "abstracttypes.h"
#include "macro.h"
namespace amussementpark {
class RingBar: public osg::Geode {
public:
RingBar(osg::Vec3 center, DOUBLE xLen, DOUBLE yLen, DOUBLE zLen);
};
class ThreadmilRing: public osg::Group {
public:
ThreadmilRing(DOUBLE radius, DOUBLE numSides);
};
class Cabinas: public osg::Group {
private:
FLOAT radio;
INT lados;
osg::ref_ptr<osg::MatrixTransform> transf1;
osg::ref_ptr<osg::MatrixTransform> transf2;
public:
Cabinas(FLOAT radio, INT lados);
osg::MatrixTransform * getAnimationCabina();
};
class Estructura: public osg::Group {
private:
osg::ref_ptr<osg::Geode> cuboEstructura1;
osg::ref_ptr<osg::Geode> cuboEstructura2;
osg::ref_ptr<osg::Geode> cuboEstructura3;
osg::ref_ptr<osg::MatrixTransform> transf1; //scale
osg::ref_ptr<osg::MatrixTransform> transf2; //rotate
osg::ref_ptr<osg::MatrixTransform> transf3; //rotate2
osg::ref_ptr<osg::MatrixTransform> transf4; //rotate3
osg::ref_ptr<osg::MatrixTransform> transf5; //rotate3
osg::ref_ptr<osg::MatrixTransform> transf6; //translate
osg::ref_ptr<osg::ShapeDrawable> sesfera;
osg::ref_ptr<osg::Geode> esfera;
osg::ref_ptr<osg::MatrixTransform> transf_esf; //translate esfera juntura
public:
Estructura();
};
class ThreadmilInstance: public MovableObject {
private:
DOUBLE speed;
DOUBLE speedIncrease;
BOOLEAN enabled;
osg::MatrixTransform* ringMovement;
osg::ref_ptr<Cabinas> cabinas;
public:
ThreadmilInstance();
void onKeyPress();
void onCtrlKeyPress();
void onMouseClick();
void updateAnimation();
};
}
#endif