diff --git a/include/osg/KdTree b/include/osg/KdTree index 735248f5e..2ef9add11 100644 --- a/include/osg/KdTree +++ b/include/osg/KdTree @@ -83,7 +83,7 @@ class OSG_EXPORT KdTree : public osg::Shape typedef std::vector LineSegmentIntersections; /** compute the intersection of a line segment and the kdtree, return true if an intersection has been found.*/ - virtual bool intersect(const osg::Vec3& start, const osg::Vec3& end, LineSegmentIntersections& intersections) const; + virtual bool intersect(const osg::Vec3d& start, const osg::Vec3d& end, LineSegmentIntersections& intersections) const; typedef int value_type; diff --git a/src/osg/KdTree.cpp b/src/osg/KdTree.cpp index 64d19ef64..33c26019c 100644 --- a/src/osg/KdTree.cpp +++ b/src/osg/KdTree.cpp @@ -431,7 +431,7 @@ struct IntersectKdTree const KdTree::KdNodeList& nodes, const KdTree::TriangleList& triangles, KdTree::LineSegmentIntersections& intersections, - const osg::Vec3& s, const osg::Vec3& e): + const osg::Vec3d& s, const osg::Vec3d& e): _vertices(vertices), _kdNodes(nodes), _triangles(triangles), @@ -764,7 +764,7 @@ bool KdTree::build(BuildOptions& options, osg::Geometry* geometry) return build.build(options, geometry); } -bool KdTree::intersect(const osg::Vec3& start, const osg::Vec3& end, LineSegmentIntersections& intersections) const +bool KdTree::intersect(const osg::Vec3d& start, const osg::Vec3d& end, LineSegmentIntersections& intersections) const { if (_kdNodes.empty()) {