Skip to content

Commit

Permalink
Rename barycenter function
Browse files Browse the repository at this point in the history
  • Loading branch information
JacksonCampolattaro committed Jul 21, 2020
1 parent ca08d16 commit 110744d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Octree/include/CGAL/Octree.h
Expand Up @@ -322,7 +322,7 @@ class Octree {
while (!node_for_point->is_leaf()) {

// Find the point to split around
Point center = compute_barycenter_position(*node_for_point);
Point center = barycenter(*node_for_point);

// Find the index of the correct sub-node
typename Node::Index index;
Expand Down Expand Up @@ -464,7 +464,7 @@ class Octree {

private: // functions :

Point compute_barycenter_position(const Node &node) const {
Point barycenter(const Node &node) const {

// Determine the side length of this node
FT size = m_side_per_depth[node.depth()];
Expand Down Expand Up @@ -517,7 +517,7 @@ class Octree {
node.split();

// Find the point to around which the node is split
Point center = compute_barycenter_position(node);
Point center = barycenter(node);

// Add the node's points to its children
reassign_points(node, node.points().begin(), node.points().end(), center);
Expand Down Expand Up @@ -607,7 +607,7 @@ class Octree {
// Add a child to the list, with its distance
children_with_distances.push_back(
{typename Node::Index(index),
CGAL::squared_distance(search_bounds.center(), compute_barycenter_position(child_node))}
CGAL::squared_distance(search_bounds.center(), barycenter(child_node))}
);
}

Expand Down

0 comments on commit 110744d

Please sign in to comment.