Use number_of_parts for is_splittable

It's there, why not use it
This commit is contained in:
Sijmen Schoon 2019-03-29 01:27:20 +01:00 committed by bubnikv
parent 4a9e05194c
commit cd3cec3e45
4 changed files with 1 additions and 25 deletions

View file

@ -338,19 +338,6 @@ void TriangleMesh::rotate(double angle, Point* center)
this->translate(c(0), c(1), 0);
}
/**
* Calculates whether or not the mesh is splittable.
*/
bool TriangleMesh::is_splittable() const
{
std::vector<bool> visited;
find_unvisited_neighbors(visited);
// Try finding an unvisited facet. If there are none, the mesh is not splittable.
auto it = std::find(visited.begin(), visited.end(), false);
return it != visited.end();
}
/**
* Visit all unvisited neighboring facets that are reachable from the first unvisited facet,
* and return them.