I'm just starting to play around with openscenegraph and I'd like to know if 
what I'm describing is possible. I have two nodes, which may both have paths. 
I'd like to attach a line of sight camera between the two nodes in such a way 
that the camera is aiming at node 1 from node 2 at all times. I'd then also 
like to be able to zoom in and out relative to this line of sight.

I tried setting up a NodeTrackerManiulator, but that class seems to be able to 
freely track just one node. However, I need something that can track a node 
with camera movement constrained by another node. I tried something like the 
following:


Code:

osg::ref_ptr<osgGA::NodeTrackerManipulator> manip2 = new 
osgGA::NodeTrackerManipulator;
        manip2->setTrackNode(plane);
        manip2->setNode(sensor);
        manip2->setTrackerMode(osgGA::NodeTrackerManipulator::NODE_CENTER);
        addView(manip2.get());




but it seems to still freely track just the plane node.

Thanks in advance,

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=62724#62724





_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to