View Issue Details

IDProjectCategoryView StatusLast Update
0002723FreeCADBugpublic2016-10-09 21:36
Reporterfabien.cherblanc Assigned To 
Status closedResolutionfixed 
PlatformLinuxOSUbuntu 14.04OS Version14.04
Product Version0.17 
Fixed in Version0.17 
Summary0002723: Vertex ordering of Face
DescriptionWhile listing the vertices of a wire extracted from a face (see the python code in Steps To Reproduce), the vertices are not ordered correctly, 2 vertices are shifted.
Using the method wire.fixWire() does not correct the problem, while it should do.

Actually, the use of BRepTools_WireExplorer method (see the pythonOCC code in Additional Information) gives the correct list of vertices.
Maybe, the method TopoShapeFacePy::getOuterWire(void) could be written using the BRepTools_WireExplorer method.
Steps To Reproduceimport FreeCAD as F
import Part as FP

fichier = "face.brep"
face =[0]

wire = face.OuterWire

for v in wire.Vertexes:
    print v.X,v.Y
Additional Informationvertex_explorer = BRepTools_WireExplorer(wire)
while vertex_explorer.More() == True:
    vertex = vertex_explorer.CurrentVertex()
    pt = BRep_Tool.Pnt(vertex);
    print pt.X(), pt.Y()
TagsNo tags attached.
FreeCAD Information



2016-10-04 18:10


face.brep (Attachment missing)


2016-10-09 21:35

administrator   ~0007353

There is now a new attribute OrderedVertexes of Part.Wire

wire = face.OuterWire
for v in wire.OrderedVertexes:
    print ("%f %f %f" % (v.X,v.Y,v.Z))

Related Changesets

FreeCAD: master 58359dd0

2016-10-09 23:33:23


Details Diff
issue 0002723: Vertex ordering of Face Affected Issues
mod - src/Mod/Part/App/TopoShapeWirePy.xml Diff File
mod - src/Mod/Part/App/TopoShapeWirePyImp.cpp Diff File

Issue History

Date Modified Username Field Change
2016-10-04 18:10 fabien.cherblanc New Issue
2016-10-04 18:10 fabien.cherblanc File Added: face.brep
2016-10-09 21:33 wmayer Changeset attached => FreeCAD Master master 58359dd0
2016-10-09 21:35 wmayer Note Added: 0007353
2016-10-09 21:36 wmayer Status new => closed
2016-10-09 21:36 wmayer Resolution open => fixed
2016-10-09 21:36 wmayer Fixed in Version => 0.17