Hi, I'm trying to access a child node to perform Position Attitude Transformations but I am unable to figure out how to do so.
My createModel(overlay, technique) is defined as follows: > .... > .... > osg::Group* root = new osg::Group; > > // float baseHeight = center.z()-radius*0.5; > float baseHeight = 0; > osg::Node* baseModel = createBase(osg::Vec3(center.x(), center.y(), > baseHeight),radius); > osg::Node* movingModel = createFrustumGeode(2,4,45,45); > > if (overlay) > { > osgSim::OverlayNode* overlayNode = new osgSim::OverlayNode(technique); > overlayNode->setContinuousUpdate(true); > overlayNode->setOverlaySubgraph(movingModel); > overlayNode->setOverlayBaseHeight(baseHeight-0.01); > overlayNode->addChild(baseModel); > root->addChild(overlayNode); > } > else > { > > root->addChild(baseModel); > } > > root->addChild(movingModel); > > return root; > } > > My main function has this code: > .... > .... > > // initialize the viewer. > osgViewer::Viewer viewer; > > // load the nodes from the commandline arguments. > osg::Node* model = createModel(overlay, technique); > if (!model) > { > return 1; > } Now at this point in my main function, I want to access the child node of model (say the "movingModel" node) and perform a position attitude transformation on it. How do I access it and perform the transformation? Any suggestions would be welcomed by this newbie. Thank you! Cheers, John ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=25923#25923 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org