Hi,

It really depends on how big your point cloud is. General rule is to create 
tree (kd-tree, octree, ...). Either multiple nodes or on big custom drawable 
with tree in it. If you create custom drawable, you can test if ray intersects 
tree node or polytope contains tree node. If you create tree with 
osg::Nodes(Groups), osgUtil::Polytope intersector will do the job for you. But 
you would need to aguament it to contain all your intersections (if you would 
have many intersection I recommend three sets -> 1) nodes completely in 
polytope, 2) nodes partially in polytope 3) nodes completely outside polytope. 

2D window rectangle polytope can be created in window coordinates:
osgUtil::PolytopeIntersector (osgUtil::PolytopeIntersector::WINDOW, xMin, yMin, 
xMax, yMax)
Cheers,
Filip

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





_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to