forked from bobsayshilol/engine-sim
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsimulation_object.h
More file actions
42 lines (34 loc) · 1.06 KB
/
simulation_object.h
File metadata and controls
42 lines (34 loc) · 1.06 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
#ifndef ATG_ENGINE_SIM_SIMULATION_OBJECT_H
#define ATG_ENGINE_SIM_SIMULATION_OBJECT_H
#include "scs.h"
#include "delta.h"
class Piston;
class CylinderBank;
class EngineSimApplication;
class SimulationObject {
public:
struct ViewParameters {
int Layer0;
int Layer1;
};
public:
SimulationObject();
virtual ~SimulationObject();
virtual void initialize(EngineSimApplication *app);
virtual void generateGeometry();
virtual void render(const ViewParameters *settings);
virtual void process(float dt);
virtual void destroy();
Piston *getForemostPiston(CylinderBank *bank, int layer);
protected:
void resetShader();
void setTransform(
atg_scs::RigidBody *rigidBody,
float scale = 1.0f,
float lx = 0.0f,
float ly = 0.0f,
float theta = 0.0f);
ysVector tintByLayer(const ysVector &col, int layers) const;
EngineSimApplication *m_app;
};
#endif /* ATG_ENGINE_SIM_SIMULATION_OBJECT_H */