-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDOF.h
67 lines (54 loc) · 1.17 KB
/
DOF.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
#ifndef DOF_H
#define DOF_H
#include <QString>
#include <QHash>
class DOF
{
public:
enum Type {
RotationX,
RotationY,
RotationZ,
TranslationX,
TranslationY,
TranslationZ,
ColorR,
ColorG,
ColorB,
ColorA,
Diffuse,
Specular,
MorphTarget,
AnimSpeed,
None
};
DOF(Type type = None, bool enabled = false);
virtual ~DOF();
float value() const;
void setValue(float val);
bool hasMin() const;
void setHasMin(bool hasMin);
float min() const;
void setMin(float val);
bool hasMax() const;
void setHasMax(bool hasMax);
float max() const;
void setMax(float val);
bool isEnabled() const;
void setEnabled(bool enabled);
QString const& name() const;
void setName(QString const& name);
Type type() const;
void setType(Type type);
private:
bool _hasMin;
float _min;
bool _hasMax;
float _max;
float _value;
QString _name;
bool _enabled;
Type _type;
static QHash<Type, QString> _names;
};
#endif // DOF_H