Edge,face,vertex orientation

Technical discussions
Post Reply
George Silva
Posts: 4
Joined: Fri Jun 14, 2019 3:30 am

Edge,face,vertex orientation

Post by George Silva »

Hello
I believe Dgkernel is interfacing to Open Cascade. This is where my experience is. Can anybody clarify why I do not see get/set orientation for an edge and other sub-shapes in the IEgde_DG, etc?
Thank you in advance
George Silva

Prashant Kande
Posts: 121
Joined: Mon Apr 04, 2016 4:55 am

Re: Edge,face,vertex orientation

Post by Prashant Kande »

Hi George

Orientation in Open Cascade is related to how an edge or vertex is oriented relative to its parent shape. This assumes that the object is a value object and has a unique parent.
Orientation is trivial for vertices. The first end of an edge is vertex with positive orientation. The other end is negative. So, apart from faces in rarely used composite solids, orientation is important only for edges.

An edge is oriented positive if it goes in CCW direction in the face (second vertex is geometrically next in CCW direction after the first vertex.

DGK handles shapes by reference. So, an IBRepEdge_DG is shared by two adjacent faces. DGK shapes do not have an orientation by itself. Instead, given a face and its edge, you can determine orientation of the edge relative to the face using IBRepWire_DG.IsEdgeReversed(): http://www.dynoinsight.com/Help/V6_0/In ... geReversed.

Wires are not shared. They are a property of its face
Last edited by Prashant Kande on Wed Jun 19, 2019 4:53 am, edited 1 time in total.

George Silva
Posts: 4
Joined: Fri Jun 14, 2019 3:30 am

Re: Edge,face,vertex orientation

Post by George Silva »

Thank you for that
I assume the index parameter is index of the edge in the wire? How do I get it?
Thanks

Prashant Kande
Posts: 121
Joined: Mon Apr 04, 2016 4:55 am

Re: Edge,face,vertex orientation

Post by Prashant Kande »

Yes, George
Please use IBRepWire_DG.GetEdge() and IBRepShape_DG.IsEqual() to search for the index. We will add a shortcut for this in 6.2.
Cheers

Post Reply