osg坐标位置转换

osg::Vec3f vec3f1 = hookNode->getBound().center();
osg::NodePathList nodePAthList1 = hookNode->getParentalNodePaths(0);
updateHookPosition_20190914(vec3f1, nodePAthList1);
osg::Vec3 point3 = vec3f1 * osg::computeLocalToWorld(nodePath1);
std::cout << "hook x:" << point3.x() << "  y:" << point3.y() << "  z:" << point3.z() << std::endl;

 

posted @ 2019-09-14 11:56  西北逍遥  阅读(978)  评论(0编辑  收藏  举报