How to get list of surfaces from polysurface


How to get list of trimmed surfaces from polysurfaces using C#


Brepfaces are stored in list brep.Faces.

                        // Brep brep =   .....  is a brep (polysurface)
                        for (int i = 0; i < brep.Faces.Count; i++)
                            // brep.Faces[i] - brep face
                            var singleFaceBrep = brep.Faces[i].DuplicateFace(true); //trimed surface
                            var untrimedSurface = brep.Faces[i].DuplicateSurface();
1 Like

Its working…:slightly_smiling_face:
Thanks @RadovanG