sofa::component::contextobject::CoordinateSystem Class Reference

Defines the local coordinate system with respect to its parent. More...

#include <CoordinateSystem.h>

Inheritance diagram for sofa::component::contextobject::CoordinateSystem:

Inheritance graph
[legend]
Collaboration diagram for sofa::component::contextobject::CoordinateSystem:

Collaboration graph
[legend]

Public Types

typedef
core::objectmodel::BaseContext::SolidTypes 
SolidTypes
typedef SolidTypes::Vec Vec
typedef SolidTypes::Rot Rot
typedef SolidTypes::Mat Mat
typedef SolidTypes::Coord Frame
typedef SolidTypes::Deriv SpatialVector

Public Member Functions

 CoordinateSystem ()
virtual ~CoordinateSystem ()
virtual void apply ()
 modify the Context
virtual void draw ()
 Render internal data of this object, for debugging purposes.
virtual void reinit ()
 Update method called when variables used in precomputation are modified.
virtual void init ()
 Initialization method called at graph modification, during bottom-up traversal.
const Frame & getTransform () const
 Transform wrt parent.
virtual void setTransform (const Frame &f)
 Transform wrt parent.
Vec getOrigin () const
 Transform wrt world.
Rot getOrientation () const
 Define orientation (rotation of the child wrt parent) in parent coordinates.

Data Fields

Data< defaulttype::Vec3f > origin
 Define translation and orientation in parent coordinates.
Data< defaulttype::Vec3f > orientation

Protected Attributes

Frame positionInParent_
 wrt parent frame

Detailed Description

Defines the local coordinate system with respect to its parent.

Definition at line 65 of file CoordinateSystem.h.


Member Typedef Documentation

Definition at line 72 of file CoordinateSystem.h.

Definition at line 71 of file CoordinateSystem.h.

Definition at line 70 of file CoordinateSystem.h.

Definition at line 68 of file CoordinateSystem.h.

Definition at line 73 of file CoordinateSystem.h.

Definition at line 69 of file CoordinateSystem.h.


Constructor & Destructor Documentation

sofa::component::contextobject::CoordinateSystem::CoordinateSystem (  ) 

Definition at line 47 of file CoordinateSystem.cpp.

virtual sofa::component::contextobject::CoordinateSystem::~CoordinateSystem (  )  [inline, virtual]

Definition at line 76 of file CoordinateSystem.h.


Member Function Documentation

void sofa::component::contextobject::CoordinateSystem::apply (  )  [virtual]

void sofa::component::contextobject::CoordinateSystem::draw (  )  [virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

Definition at line 151 of file CoordinateSystem.cpp.

CoordinateSystem::Rot sofa::component::contextobject::CoordinateSystem::getOrientation ( void   )  const

Define orientation (rotation of the child wrt parent) in parent coordinates.

Orientation (rotation of the child wrt parent)

Definition at line 87 of file CoordinateSystem.cpp.

References sofa::defaulttype::SolidTypes< R >::Transform::getOrientation(), and positionInParent_.

CoordinateSystem::Vec sofa::component::contextobject::CoordinateSystem::getOrigin (  )  const

Transform wrt world.

Define translation in parent coordinates Translation in parent coordinates

Definition at line 76 of file CoordinateSystem.cpp.

References sofa::defaulttype::SolidTypes< R >::Transform::getOrigin(), and positionInParent_.

Referenced by apply().

const CoordinateSystem::Frame & sofa::component::contextobject::CoordinateSystem::getTransform (  )  const

Transform wrt parent.

Definition at line 60 of file CoordinateSystem.cpp.

References positionInParent_.

Referenced by apply().

void sofa::component::contextobject::CoordinateSystem::init ( void   )  [virtual]

Initialization method called at graph modification, during bottom-up traversal.

Reimplemented from sofa::core::objectmodel::BaseObject.

Definition at line 184 of file CoordinateSystem.cpp.

References reinit().

void sofa::component::contextobject::CoordinateSystem::reinit (  )  [virtual]

Update method called when variables used in precomputation are modified.

Reimplemented from sofa::core::objectmodel::BaseObject.

Definition at line 175 of file CoordinateSystem.cpp.

References sofa::helper::Quater< Real >::createFromRotationVector(), orientation, origin, and setTransform().

Referenced by init().

void sofa::component::contextobject::CoordinateSystem::setTransform ( const Frame &  f  )  [virtual]

Transform wrt parent.

Definition at line 65 of file CoordinateSystem.cpp.

References positionInParent_.

Referenced by reinit().


Field Documentation

Definition at line 113 of file CoordinateSystem.h.

Referenced by reinit().

Define translation and orientation in parent coordinates.

wrt world, given in world coordinates wrt parent frame, given in LOCAL frame wrt parent frame, given in LOCAL frame

Definition at line 112 of file CoordinateSystem.h.

Referenced by reinit().

wrt parent frame

Definition at line 115 of file CoordinateSystem.h.

Referenced by getOrientation(), getOrigin(), getTransform(), and setTransform().


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

Generated on Sun Nov 23 04:18:33 2008 for Sofa by  doxygen 1.5.7.1