15 #ifndef PHYSICSMANAGER_H 16 #define PHYSICSMANAGER_H 18 #include "pandabase.h" 19 #include "pointerTo.h" 22 #include "linearForce.h" 23 #include "angularForce.h" 24 #include "linearIntegrator.h" 25 #include "angularIntegrator.h" 26 #include "physicalNode.h" 31 #include "configVariableInt.h" 58 INLINE
void attach_physical(
Physical *p);
63 INLINE
void clear_linear_forces();
64 INLINE
void clear_angular_forces();
65 INLINE
void clear_physicals();
67 INLINE
void set_viscosity(PN_stdfloat viscosity);
68 INLINE PN_stdfloat get_viscosity()
const;
74 void do_physics(PN_stdfloat dt);
75 void do_physics(PN_stdfloat dt,
Physical *p);
76 void init_random_seed();
78 virtual void output(ostream &out)
const;
79 virtual void write_physicals(ostream &out,
unsigned int indent=0)
const;
80 virtual void write_linear_forces(ostream &out,
unsigned int indent=0)
const;
81 virtual void write_angular_forces(ostream &out,
unsigned int indent=0)
const;
82 virtual void write(ostream &out,
unsigned int indent=0)
const;
84 virtual void debug_output(ostream &out,
unsigned int indent=0)
const;
91 PN_stdfloat _viscosity;
92 PhysicalsVector _physicals;
93 LinearForceVector _linear_forces;
94 AngularForceVector _angular_forces;
100 #include "physicsManager.I" 102 #endif // PHYSICSMANAGER_H Pure virtual base class for physical modeling.
A force that acts on a PhysicsObject by way of an Integrator.
Graph node that encapsulated a series of physical objects.
Physics don't get much higher-level than this.
Defines a set of physically modeled attributes.
pure virtual parent of all quat-based forces.
Pure virtual base class for physical modeling.
This is a convenience class to specialize ConfigVariable as an integer type.