Hi,
i am trying to do animation about own axis of object
itself but i am not getting correctly.
Code:
virtual void operator()(osg::Node* node, osg::NodeVisitor* nv)
{
if (nv->getVisitorType() == osg::NodeVisitor::UPDATE_VISITOR)
{
osg::MatrixTransform* MT =
dynamic_cast<osg::MatrixTransform*>(node);
if (MT) {
osg::Vec3 result(0,1,0);
osg::Matrix Rot;
Rot.makeRotate(1,result);
MT->setMatrix(Rot*MT->getMatrix());
}
}
///traverse(node,nv);
}
]
Please help me i am just learning OSG
Thank you!
Cheers,
Rakesh
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29882#29882
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org