SoPhysicsCapsule Class Reference
[libipsa classesPhysic Classes]

Defines a physics object with the properties of a capsule (also called capped cylinder). More...

#include <SoPhysicsCapsule.h>

Inheritance diagram for SoPhysicsCapsule:

Inheritance graph
[legend]
Collaboration diagram for SoPhysicsCapsule:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 SoPhysicsCapsule (const SbString &nodeName="")

Static Public Member Functions

static void initClass ()

Protected Member Functions

virtual dMass getInitialMass ()
virtual void updateDependentObjects ()

Private Member Functions

 SO_KIT_HEADER (SoPhysicsCapsule)


Detailed Description

Defines a physics object with the properties of a capsule (also called capped cylinder).

A capsule (capped cylinder) is like a normal cylinder except it has half-sphere caps at its ends.

Warning:
This physics object is not scaleable.

SoPhysicsCylinder::initClass() must be called before SoPhysicsCapsule::initClass()

Capsule.png

A capsule

Definition at line 30 of file SoPhysicsCapsule.h.


Constructor & Destructor Documentation

SoPhysicsCapsule::SoPhysicsCapsule ( const SbString &  nodeName = ""  ) 

The constructor of SoPhysicsCapsule.

Parameters:
nodeName name of the node in the Inventor scenegraph

Definition at line 54 of file SoPhysicsCapsule.cpp.


Member Function Documentation

dMass SoPhysicsCapsule::getInitialMass (  )  [protected, virtual]

This method returns the mass of the capped cylinder object. The mass of the object that will be returned is calculated by taking care of changes in scaling.

Returns:
mass: the mass of the capped cylinder.

Reimplemented from SoPhysicsCylinder.

Definition at line 78 of file SoPhysicsCapsule.cpp.

References SoPhysics::inertia, SoPhysics::mass, and SoPhysics::scale.

void SoPhysicsCapsule::initClass (  )  [static]

Initialises the class and it's type id variables.

Reimplemented from SoPhysicsCylinder.

Definition at line 44 of file SoPhysicsCapsule.cpp.

SoPhysicsCapsule::SO_KIT_HEADER ( SoPhysicsCapsule   )  [private]

void SoPhysicsCapsule::updateDependentObjects (  )  [protected, virtual]

If one of the fields of the object changes these changes are propagated to the collision and visualisation shape if they are of the same type as the physics object. If the field SoPhysics::AUTO_UPDATE_COLLISION_SHAPE is set to FALSE the collision shape doesn't get uptdated.

Reimplemented from SoPhysicsCylinder.

Definition at line 112 of file SoPhysicsCapsule.cpp.


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

Get IPSA - Inventor Physics Simulation API at SourceForge.net. Fast, secure and Free Open Source software downloads
Generated on Sat Mar 10 20:00:21 2012 for IPSA by  doxygen 1.5.8