Further work on PlaneIntersector
This commit is contained in:
@@ -24,7 +24,7 @@ namespace osg {
|
||||
* Note, if no slave cameras are attached to the view then the master camera does both the control and implementation of the rendering of the scene,
|
||||
* but if slave cameras are present then the master controls the view onto the scene, while the slaves implement the rendering of the scene.
|
||||
*/
|
||||
class OSG_EXPORT View : public osg::Referenced
|
||||
class OSG_EXPORT View : public virtual osg::Referenced
|
||||
{
|
||||
public :
|
||||
|
||||
|
||||
@@ -37,13 +37,22 @@ class OSGUTIL_EXPORT PlaneIntersector : public Intersector
|
||||
|
||||
bool operator < (const Intersection& rhs) const
|
||||
{
|
||||
if (polyline < rhs.polyline) return true;
|
||||
if (rhs.polyline < polyline) return false;
|
||||
|
||||
if (nodePath < rhs.nodePath) return true;
|
||||
if (rhs.nodePath < nodePath ) return false;
|
||||
|
||||
return (drawable < rhs.drawable);
|
||||
}
|
||||
|
||||
typedef std::vector<osg::Vec3d> Polyline;
|
||||
|
||||
osg::NodePath nodePath;
|
||||
osg::ref_ptr<osg::RefMatrix> matrix;
|
||||
osg::ref_ptr<osg::Drawable> drawable;
|
||||
Polyline polyline;
|
||||
|
||||
};
|
||||
|
||||
typedef std::set<Intersection> Intersections;
|
||||
|
||||
Reference in New Issue
Block a user