BRep_Tool::Triangulation always IsNull

How to check why triangulation.IsNull() when BRepMesh_IncrementalMesh mesher(localFace, deflection, Standard_True); is success? What is wrong?

TopLoc_Location location;
Handle(Poly_Triangulation) triangulation = BRep_Tool::Triangulation(localFace, location);
if (triangulation.IsNull()) {
std::cerr << "Error: No triangulation found for the face!" << std::endl;
return 1;
}

Dmitrii Pasukhin's picture

Hello. You can validate your model using BRepCheck_Analyzer.

The mesh for some faces can be not build based on the problem on topology level.

Best regards, Dmitrii.