opal::SolidData Class Reference

A data structure describing a Solid. More...

#include <SolidData.h>

List of all members.

Public Member Functions

OPAL_DECL SolidData ()
OPAL_DECL SolidData (const SolidData &data)
virtual OPAL_DECL ~SolidData ()
virtual OPAL_DECL void OPAL_CALL addShape (const ShapeData &data)
virtual OPAL_DECL unsigned
int OPAL_CALL 
getNumShapes () const
virtual OPAL_DECL ShapeData
*OPAL_CALL 
getShapeData (unsigned int i) const
virtual OPAL_DECL void OPAL_CALL destroyShapes ()
virtual OPAL_DECL void OPAL_CALL operator= (const SolidData &data)

Public Attributes

bool enabled
std::string name
bool sleeping
real sleepiness
bool isStatic
Matrix44r transform
Vec3r globalLinearVel
Vec3r globalAngularVel
real linearDamping
real angularDamping

Protected Attributes

std::vector< ShapeData * > mShapes


Detailed Description

A data structure describing a Solid.

Definition at line 37 of file SolidData.h.


Constructor & Destructor Documentation

opal::SolidData::SolidData  ) 
 

Definition at line 37 of file SolidData.cpp.

References opal::defaults::solid::angularDamping, angularDamping, opal::defaults::solid::enabled, enabled, opal::defaults::solid::isStatic, isStatic, opal::defaults::solid::linearDamping, linearDamping, name, opal::defaults::solid::sleepiness, sleepiness, opal::defaults::solid::sleeping, and sleeping.

opal::SolidData::SolidData const SolidData data  ) 
 

Copy constructor.

Definition at line 52 of file SolidData.cpp.

opal::SolidData::~SolidData  )  [virtual]
 

Definition at line 57 of file SolidData.cpp.

References destroyShapes().


Member Function Documentation

void opal::SolidData::addShape const ShapeData data  )  [virtual]
 

Adds a new Shape to the SolidData. This automatically allocates the right ShapeData type.

Definition at line 62 of file SolidData.cpp.

References opal::BOX_SHAPE, and opal::ShapeData::getType().

Referenced by operator=().

void opal::SolidData::destroyShapes  )  [virtual]
 

Destroys all Shapes in the SolidData.

Definition at line 115 of file SolidData.cpp.

References mShapes.

Referenced by opal::ODESolid::clearShapes(), opal::ODESolid::init(), operator=(), and ~SolidData().

unsigned int opal::SolidData::getNumShapes  )  const [virtual]
 

Returns the number of Shapes in this SolidData.

Definition at line 105 of file SolidData.cpp.

References mShapes.

Referenced by opal::ODESolid::init().

ShapeData * opal::SolidData::getShapeData unsigned int  i  )  const [virtual]
 

Returns a pointer to the ShapeData at the given index.

Definition at line 110 of file SolidData.cpp.

References mShapes.

Referenced by opal::ODESolid::init().

void opal::SolidData::operator= const SolidData data  )  [virtual]
 

Makes a deep copy.

Definition at line 124 of file SolidData.cpp.

References addShape(), angularDamping, destroyShapes(), enabled, globalAngularVel, globalLinearVel, isStatic, linearDamping, mShapes, name, sleepiness, sleeping, and transform.


Member Data Documentation

real opal::SolidData::angularDamping
 

The amount of damping applied to the Solid's angular motion.

Definition at line 93 of file SolidData.h.

Referenced by opal::Solid::getAngularDamping(), operator=(), opal::Solid::setAngularDamping(), and SolidData().

bool opal::SolidData::enabled
 

Determines whether the Solid is enabled.

Definition at line 65 of file SolidData.h.

Referenced by opal::Solid::addForce(), opal::Solid::isEnabled(), operator=(), opal::Solid::setEnabled(), and SolidData().

Vec3r opal::SolidData::globalAngularVel
 

The Solid's angular velocity in global coordinates.

Definition at line 87 of file SolidData.h.

Referenced by operator=().

Vec3r opal::SolidData::globalLinearVel
 

The Solid's linear velocity in global coordinates.

Definition at line 84 of file SolidData.h.

Referenced by operator=().

bool opal::SolidData::isStatic
 

Determines whether the Solid is static.

Definition at line 78 of file SolidData.h.

Referenced by opal::Solid::addForce(), opal::ODESolid::addMass(), opal::ODESolid::getGlobalAngularVel(), opal::ODESolid::getGlobalLinearVel(), opal::ODESolid::getGlobalLinearVelAtLocalPos(), opal::ODESolid::getInertiaTensor(), opal::ODESolid::getLocalAngularVel(), opal::ODESolid::getLocalLinearVel(), opal::ODESolid::getLocalLinearVelAtLocalPos(), opal::ODESolid::getMass(), opal::ODESolid::init(), opal::Solid::internal_applyForces(), opal::ODESolid::internal_updateEngineTransform(), opal::ODESolid::isSleeping(), opal::Solid::isStatic(), opal::ODESolid::ODESolid(), operator=(), opal::ODESolid::setEnabled(), opal::ODESolid::setGlobalAngularVel(), opal::ODESolid::setGlobalLinearVel(), opal::ODESolid::setLocalAngularVel(), opal::ODESolid::setLocalLinearVel(), opal::ODESolid::setMass(), opal::ODESolid::setSleepiness(), opal::ODESolid::setSleeping(), opal::ODESolid::setStatic(), opal::ODESolid::setupNewGeom(), SolidData(), opal::ODESolid::translateMass(), opal::ODESolid::zeroForces(), and opal::ODESolid::~ODESolid().

real opal::SolidData::linearDamping
 

The amount of damping applied to the Solid's linear motion.

Definition at line 90 of file SolidData.h.

Referenced by opal::Solid::getLinearDamping(), operator=(), opal::Solid::setLinearDamping(), and SolidData().

std::vector<ShapeData*> opal::SolidData::mShapes [protected]
 

Pointers to the Solid's Shape data.

Definition at line 97 of file SolidData.h.

Referenced by destroyShapes(), getNumShapes(), getShapeData(), and operator=().

std::string opal::SolidData::name
 

An identifier for the Solid.

Definition at line 68 of file SolidData.h.

Referenced by opal::Blueprint::addSolid(), opal::Solid::getName(), operator=(), opal::Solid::setName(), and SolidData().

real opal::SolidData::sleepiness
 

The Solid's sleepiness level which determines how fast the Solid falls asleep.

Definition at line 75 of file SolidData.h.

Referenced by opal::Solid::getSleepiness(), operator=(), opal::Solid::setSleepiness(), opal::ODESolid::setStatic(), and SolidData().

bool opal::SolidData::sleeping
 

Determines whether the Solid is sleeping.

Definition at line 71 of file SolidData.h.

Referenced by opal::Solid::getData(), operator=(), and SolidData().

Matrix44r opal::SolidData::transform
 

The Solid's transform relative to the global origin.

Definition at line 81 of file SolidData.h.

Referenced by opal::Solid::getEulerXYZ(), opal::Solid::getGlobalAABB(), opal::Solid::getPosition(), opal::Solid::getQuaternion(), opal::Solid::getTransform(), opal::ODESolid::init(), opal::ODESolid::internal_updateEngineTransform(), opal::ODESolid::internal_updateOPALTransform(), operator=(), opal::Solid::setPosition(), opal::Solid::setQuaternion(), opal::ODESolid::setStatic(), opal::Solid::setTransform(), and opal::ODESolid::setupNewGeom().


The documentation for this class was generated from the following files:
Generated on Tue May 16 17:49:58 2006 for OPAL by  doxygen 1.4.6-NO