cisst-saw
|
Transformation base class. More...
#include <prmTransformationBase.h>
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 |
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
typedef std::list<prmTransformationBasePtr> prmTransformationBase::NodeListType |
|
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.
|
inline |
Constructor with a name only.
|
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.
|
inline |
Set/Get name
|
inline |
Get a pointer to the reference frame.
|
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.
newReference | prmTransformationBasePtr ptr to new location in the tree |
bool prmTransformationBase::SetReferenceFrame | ( | const std::string & | parentName | ) |
prmTransformationBasePtr prmTransformationBase::WorldFrame | ( | void | ) |
|
pure virtual |
Get the transformation between the reference frame and this frame.
Implemented in prmTransformationDynamic, and prmTransformationFixed.
|
friend |
|
protected |
frames that attach and refer to this frame
|
protected |
a describable name
|
protected |
a reference to its parent and immediate reference frame, obtained during prmTransformationManager::Attach