Skip to content

Commit

Permalink
assert improvement to allow debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
Denis Haumont committed May 22, 2024
1 parent b0da0bb commit 018de39
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions visilib/plucker_polytope_splitter.h
Original file line number Diff line number Diff line change
Expand Up @@ -271,19 +271,27 @@ namespace visilib
V_ASSERT(Qm != Qn);
if (!MathPredicates::isEdgeCollapsed(aPolyhedron->get(Qn), aPolyhedron->get(Qm), tolerance))
{
V_ASSERT(facetsQm.size() != facetsQn.size() || !std::equal(facetsQm.begin(), facetsQm.end(), facetsQn.begin()));

if (facetsQm.size() != facetsQn.size() || !std::equal(facetsQm.begin(), facetsQm.end(), facetsQn.begin()))
{
aLeft->addEdge(Qm, Qn, aPolyhedron);
aRight->addEdge(Qm, Qn, aPolyhedron);
}
else
{
V_ASSERT(0);
}
}
}
}
}

aLeft->removeCollapsedEdges(aPolyhedron,tolerance);
aRight->removeCollapsedEdges(aPolyhedron,tolerance);
V_ASSERT(aLeft->getEdgeCount() > 0);
V_ASSERT(aRight->getEdgeCount() > 0);
// aLeft->V_ASSERTIsValid(aPolyhedron, normalization);
// aRight->V_ASSERTIsValid(aPolyhedron, normalization);
//V_ASSERT(aLeft->isValid(aPolyhedron, normalization,tolerance));
//V_ASSERT(aRight->isValid(aPolyhedron, normalization,tolerance));

return ON_BOUNDARY;
}
}

0 comments on commit 018de39

Please sign in to comment.