-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathModifier.h
More file actions
58 lines (40 loc) · 1.07 KB
/
Modifier.h
File metadata and controls
58 lines (40 loc) · 1.07 KB
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
#ifndef _MODIFIER_H_
#define _MODIFIER_H_
#include "Shapes.h"
class PolyShape;
class Solid;
class Modifier {
public:
Modifier(PolyShape* bVolume);
virtual ~Modifier();
void Move(float x, float y, float z);
void Scale(float x, float y, float z);
void RotateX(float radian);
void RotateY(float radian);
void RotateZ(float radian);
int GetNumVertices();
void Apply(Solid* solid);
virtual void SelectNodes(Solid* solid);
void SetColorBufferForSelection(VisualBuffer* colBuf);
virtual void Visualize();
void VisualizeNormals();
protected:
PolyShape* bVolume;
bool* pIntersect;
VisualBuffer* colorBuffer;
float4 color;
private:
float4* vertexVbo;
float4* normalVbo;
GLuint vertexVboID;
GLuint normalVboID;
float4* vertexCpuPtr;
float4* normalCpuPtr;
float4 position;
Matrix4f* transform;
bool mainMemUpdated;
virtual void ApplyModifierStrategy(Solid* solid) = 0;
void CopyToGPU();
void LoadBoundingVolumeIntoVBO();
};
#endif // _MODIFIER_H_