Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
om::physics::forces::Force Class Referenceabstract

The interface for all classes that apply forces and torques to simulated objects. More...

#include <omPhysicsForce.h>

Inheritance diagram for om::physics::forces::Force:
om::physics::context::PhysicsSceneObject om::physics::context::PhysicsContextObject om::physics::forces::ForceField om::physics::forces::Spring om::physics::forces::Thruster om::physics::forces::GravityField

Public Member Functions

virtual ~Force ()
 Destory this force object. More...
 
virtual void applyForce (Float dt)=0
 Apply force vectors to all objects that this Force effects. More...
 
const ForceTypegetType () const
 Return an object representing the type of this Force. More...
 
- Public Member Functions inherited from om::physics::context::PhysicsSceneObject
virtual Bool addSceneObjects (PhysicsSceneID sceneID)
 Add internal context objects to the scene with the specified ID. More...
 
virtual Bool removeSceneObjects (PhysicsSceneID sceneID)
 Remove internal context objects from the scene with the specified ID. More...
 
- Public Member Functions inherited from om::physics::context::PhysicsContextObject
virtual ~PhysicsContextObject ()
 Destory this physics context object. More...
 
PhysicsContextgetContext () const
 Return a pointer to the physics context this context object is using to do simulation. More...
 
virtual Bool setContext (PhysicsContext *newContext)
 Set a pointer to the physics context this context object should use to do simulation. More...
 
Bool clearContext ()
 Clear the previous context from this object. More...
 

Static Public Attributes

static const ResourceType RESOURCE_TYPE
 The resource type for a force. More...
 

Protected Member Functions

 Force (const ForceType *newType)
 Create a Force object that has the specified type. More...
 
- Protected Member Functions inherited from om::physics::context::PhysicsContextObject
 PhysicsContextObject ()
 Create a new physics context object that doesn't have an associated physics context. More...
 
 PhysicsContextObject (PhysicsContext *newContext)
 Create a new physics context object that uses the specified context for simulation. More...
 

Additional Inherited Members

- Protected Attributes inherited from om::physics::context::PhysicsContextObject
PhysicsContextcontext
 A pointer to the physics context this object is using. More...
 

Detailed Description

The interface for all classes that apply forces and torques to simulated objects.

Constructor & Destructor Documentation

virtual om::physics::forces::Force::~Force ( )
virtual

Destory this force object.

om::physics::forces::Force::Force ( const ForceType newType)
inlineprotected

Create a Force object that has the specified type.

Member Function Documentation

virtual void om::physics::forces::Force::applyForce ( Float  dt)
pure virtual

Apply force vectors to all objects that this Force effects.

These force vectors should be based on the internal configuration of the force system.

Implemented in om::physics::forces::Spring, om::physics::forces::Thruster, and om::physics::forces::GravityField.

const ForceType& om::physics::forces::Force::getType ( ) const
inline

Return an object representing the type of this Force.

Member Data Documentation

const ResourceType om::physics::forces::Force::RESOURCE_TYPE
static

The resource type for a force.


The documentation for this class was generated from the following file: