-1

我正在尝试使用 OpenCascade 从 IGES 文件中读取修剪后的表面。我可以得到曲面,但是如何从 Entity 144 之类的东西中得到修整曲线。边界曲线?任何帮助都会很棒。我正在寻找在被修剪表面的参数空间中定义修剪曲线的实际几何图形。

IGESControl_Reader reader; 
IFSelect_ReturnStatus stat = reader.ReadFile("144-000.igs"); 

Handle(TColStd_HSequenceOfTransient) facesList = reader.GiveList("iges-faces");
reader.TransferRoots();

Standard_Integer nbs = reader.NbShapes();
cout << nbs << endl;
for (int i = 1; i <= nbs; i++) {
  TopoDS_Shape shape = reader.Shape(i);

  TopoDS_Face& face = TopoDS::Face(shape);

  Handle(Geom_Surface) surf = BRep_Tool::Surface(face);
  Handle(Geom_BSplineSurface) bsplineSurf = GeomConvert::SurfaceToBSplineSurface(surf);

  cout << bsplineSurf->UDegree() << " " << bsplineSurf->VDegree() << endl;
}
4

1 回答 1

0

您是否尝试过 TopExp_Explorer 来探索形状并获取线/边缘然后从中获取曲线?

于 2018-10-22T14:18:45.417 回答