Code: Select all
import Part
obj = App.ActiveDocument.getObject("Surface")
bigbro = 4294967295
border=[]
for i in obj.Mesh.Facets:
for index in range(0,3):
if bigbro == i.NeighbourIndices[index]:
prev = i.Points[index-1]
next = i.Points[index-2]
current = i.Points[index]
if prev in border:
idx = border.index(prev)
border.insert(idx+1, current)
if next in border:
idx = border.index(next)
border.insert(idx, current)
else:
border.append(current)
pl=Part.makePolygon(border)
Part.show(pl)