Skip to content

Commit

Permalink
Rename PointMap to Point_map
Browse files Browse the repository at this point in the history
  • Loading branch information
JacksonCampolattaro committed Aug 12, 2020
1 parent a56ef32 commit 43302c8
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions Octree/include/CGAL/Octree.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ namespace Octree {
* and it may contain eight other nodes which further subdivide the region.
*
* \tparam Point_range is a range type that provides random access iterators over the indices of a set of points.
* \tparam PointMap is a type that maps items in the range to Point data
* \tparam Point_map is a type that maps items in the range to Point data
*/
template<class Point_range, class PointMap = Identity_property_map<typename Point_range::iterator::value_type>>
template<class Point_range, class Point_map = Identity_property_map<typename Point_range::iterator::value_type>>
class Octree {

public:
Expand All @@ -73,7 +73,7 @@ class Octree {
/*!
* \brief The point type is deduced from the type of the property map used
*/
typedef typename boost::property_traits<PointMap>::value_type Point;
typedef typename boost::property_traits<Point_map>::value_type Point;

/*!
* \brief The Kernel used is deduced from the point type
Expand Down Expand Up @@ -127,7 +127,7 @@ class Octree {
uint8_t m_max_depth_reached = 0; /* octree actual highest depth reached */

Point_range &m_ranges; /* input point range */
PointMap m_points_map; /* property map: `value_type of InputIterator` -> `Point` (Position) */
Point_map m_points_map; /* property map: `value_type of InputIterator` -> `Point` (Position) */

Point m_bbox_min; /* input bounding box min value */
FT m_bbox_side; /* input bounding box side length (cube) */
Expand All @@ -154,19 +154,19 @@ class Octree {
*/
Octree(
Point_range &point_range,
PointMap point_map = PointMap(),
Point_map point_map = Point_map(),
const FT enlarge_ratio = 1.2) :
m_ranges(point_range),
m_points_map(point_map) {

// compute bounding box that encloses all points
Iso_cuboid bbox = CGAL::bounding_box(boost::make_transform_iterator
(m_ranges.begin(),
CGAL::Property_map_to_unary_function<PointMap>(
CGAL::Property_map_to_unary_function<Point_map>(
m_points_map)),
boost::make_transform_iterator
(m_ranges.end(),
CGAL::Property_map_to_unary_function<PointMap>(
CGAL::Property_map_to_unary_function<Point_map>(
m_points_map)));

// Find the center point of the box
Expand Down Expand Up @@ -450,7 +450,7 @@ class Octree {
* \param rhs tree to compare with
* \return whether the trees have the same topology
*/
bool operator==(const Octree<Point_range, PointMap> &rhs) const {
bool operator==(const Octree<Point_range, Point_map> &rhs) const {

// Identical trees should have the same bounding box
if (rhs.m_bbox_min != m_bbox_min || rhs.m_bbox_side != m_bbox_side)
Expand All @@ -469,7 +469,7 @@ class Octree {
* \param rhs tree to compare with
* \return whether the trees have different topology
*/
bool operator!=(const Octree<Point_range, PointMap> &rhs) const {
bool operator!=(const Octree<Point_range, Point_map> &rhs) const {
return !operator==(rhs);
}

Expand Down

0 comments on commit 43302c8

Please sign in to comment.