"Bnd_Box is void" exception when running ShapeAnalysis::GetFaceUVBounds()

I was trying to get the uv-min and max parameters from a face using ShapeAnalysis::GetFaceUVBounds(), and in one case I encountered a "Bnd_Box is void" exception in Bnd_Box2d.  It was created by a surface and a wire on the surface. I can see that this line in the above method:

if ( ! sae.PCurve ( edge, F, c2d, f, l, Standard_False ) ) continue;

always continues. I suppose this shows that every edge of this face doesn't have a pcurve, but I am not very sure what it means. Does anyone know what might be wrong with this face, perhaps I need to use a different BRepBuilderAPI_MakeFace constructor? I use Open CASCADE 7.2.0.


Daniel Woodman's picture

I realised now that the pcurves were indeed missing from the edges. I fixed this using ShapeFix_Edge::FixAddPCurve().