25 #ifndef WGEPROPERTYTRANSFORMATIONCALLBACK_H
26 #define WGEPROPERTYTRANSFORMATIONCALLBACK_H
30 #include <osg/StateAttribute>
31 #include <osg/MatrixTransform>
33 #include "WGECallbackTraits.h"
34 #include "../../common/WProperties.h"
40 template <
typename ParentType = osg::Node,
typename TargetType = osg::MatrixTransform >
72 template <
typename ParentType,
typename TargetType >
80 template <
typename ParentType,
typename TargetType >
86 template <
typename ParentType,
typename TargetType >
88 osg::NodeVisitor* nv )
90 TargetType* m =
dynamic_cast< TargetType*
>( handled );
93 m->setMatrix( m_prop->get() );
This class is needed as OSG does not define a uniform callback type.
static void traverse(CallbackType *inst, HandledType *handled, osg::NodeVisitor *nv)
Call traversal method if existing for the specific callback type.
Type HandledType
The type of the element used as parameter in the () operator.