OpenFrames
|
Computes the transformation of a ReferenceFrame wrt an ancestor. More...
#include <TransformAccumulator.hpp>
Public Member Functions | |
TransformAccumulator (ReferenceFrame *root, ReferenceFrame *frame) | |
ReferenceFrame * | getRoot () |
void | setRoot (ReferenceFrame *root) |
ReferenceFrame * | getOrigin () |
bool | setOrigin (ReferenceFrame *frame) |
bool | isValid () |
osg::Matrixd & | getLocalToWorld () |
osg::Matrixd & | getWorldToLocal () |
Protected Member Functions | |
void | _init () |
Protected Attributes | |
osg::ref_ptr< DescendantTracker > | _lookAtPath |
osg::ref_ptr< TransformVisitor > | _transformVisitor |
Computes the transformation of a ReferenceFrame wrt an ancestor.
This class computes the transformation of a ReferenceFrame with respect to any of its ancestor frames. To use, just specify the root frame and the target frame then call the getLocalToWorld() or getWorldToLocal() method. The accumulated transform between root & target frames is returned.
osg::Matrixd& OpenFrames::TransformAccumulator::getLocalToWorld | ( | ) |
Get the transform from origin to its root frame
ReferenceFrame* OpenFrames::TransformAccumulator::getOrigin | ( | ) |
Get/Set the origin frame
ReferenceFrame* OpenFrames::TransformAccumulator::getRoot | ( | ) |
Get/Set the root frame
osg::Matrixd& OpenFrames::TransformAccumulator::getWorldToLocal | ( | ) |
Get the transform from the root to origin
bool OpenFrames::TransformAccumulator::isValid | ( | ) |
Check if the transform from root to origin exists.