Commit a487d284 by Philipp Adolf

Add assertions to isVertexRegular

parent 4422b074
......@@ -722,9 +722,11 @@ QVector<unsigned int> Subdivision::patchIBToTriangleIB(QVector<unsigned int> ib)
bool isVertexRegular(Triangle &triangle, Triangle::Neighbor current_neighbor, QMap<Triangle, Triangle::Neighbors> neighbors) {
unsigned int count = 1;
assert(current_neighbor.triangle != NULL);
while (count < 6 && *current_neighbor.triangle != triangle) {
count++;
current_neighbor = neighbors.value(*current_neighbor.triangle).get_neighbor(rotate_edge_name(current_neighbor.edge.name));
assert(current_neighbor.triangle != NULL);
}
return count == 6 && *current_neighbor.triangle == triangle;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment