cisst-saw
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Protected Attributes | Friends | List of all members
prmTransformationBase Class Referenceabstract

Transformation base class. More...

#include <prmTransformationBase.h>

Inheritance diagram for prmTransformationBase:
prmTransformationDynamic prmTransformationFixed

Public Types

typedef std::list
< prmTransformationBasePtr
NodeListType
 

Public Member Functions

 prmTransformationBase (void)
 
 prmTransformationBase (const std::string &name)
 
virtual ~prmTransformationBase ()
 Destructor. The frame is also removed from the frame manager. More...
 
prmTransformationBasePtr WorldFrame (void)
 
bool SetReferenceFrame (const prmTransformationBasePtr &newReference)
 
bool SetReferenceFrame (const std::string &parentName)
 
prmTransformationBasePtr GetReferenceFrame (void) const
 
virtual vctFrm3 WRTReference (void) const =0
 
const std::string & GetName (void) const
 
void SetName (const std::string &name)
 

Protected Attributes

std::string Name
 
prmTransformationBasePtr Parent
 
NodeListType Children
 

Friends

class prmTransformationManager
 

Detailed Description

Transformation base class.

The frame base class contains all the methods required to manage the relations between the different frames. Each frame corresponds to a node in the transformation tree and contains a pointer to its reference frame (edge of the tree).

The derived classes prmTransformationFixed and prmTransformationDynamic implement two different ways to compute the transformation between this frame and its reference, i.e. either a static transformation or a user provided command.

Please see the Frame Manager architecture discussion to see why this does not derive from a vctFrm3

See Also
prmTransformationManager, prmTransformationFixed, prmTransformationDynamic, vctFrm3

Member Typedef Documentation

Constructor & Destructor Documentation

prmTransformationBase::prmTransformationBase ( void  )
inline

Default constructor. Set the frame name as "Undefined" and uses the world frame as reference. The frame is automatically added to the frame manager.

prmTransformationBase::prmTransformationBase ( const std::string &  name)
inline

Constructor with a name only.

virtual prmTransformationBase::~prmTransformationBase ( )
virtual

Destructor. The frame is also removed from the frame manager.

Any frame using this frame as a reference will be modified to use its pparent as reference. If you need to change the reference frame of all depending frames, use prmTransformationManager::ReplaceReference.

Member Function Documentation

const std::string& prmTransformationBase::GetName ( void  ) const
inline

Set/Get name

prmTransformationBasePtr prmTransformationBase::GetReferenceFrame ( void  ) const
inline

Get a pointer to the reference frame.

void prmTransformationBase::SetName ( const std::string &  name)
inline
bool prmTransformationBase::SetReferenceFrame ( const prmTransformationBasePtr newReference)

Set the reference frame. This method uses the prmTransformationManager to make sure there is no cyclic dependency. If a cycle is found, returns false and doesn't update the reference frame.

Parameters
newReferenceprmTransformationBasePtr ptr to new location in the tree
Returns
bool success/failure code.
bool prmTransformationBase::SetReferenceFrame ( const std::string &  parentName)
prmTransformationBasePtr prmTransformationBase::WorldFrame ( void  )
virtual vctFrm3 prmTransformationBase::WRTReference ( void  ) const
pure virtual

Get the transformation between the reference frame and this frame.

Implemented in prmTransformationDynamic, and prmTransformationFixed.

Friends And Related Function Documentation

friend class prmTransformationManager
friend

Member Data Documentation

NodeListType prmTransformationBase::Children
protected

frames that attach and refer to this frame

std::string prmTransformationBase::Name
protected

a describable name

prmTransformationBasePtr prmTransformationBase::Parent
protected

a reference to its parent and immediate reference frame, obtained during prmTransformationManager::Attach


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