For all issues regarding the Forums use, please, refer to the Forum Rules.

Our Solutions

Need professional assistance?
Consider our:

Support Offerings

 

Need to speed up your development?
Have a look at our:

Samples & Tools

 

Need some functionality extending standard OCCT capabilities?
Check out our:

Adv. Components

Related pages

Distance and Edge Removal

Jacques Coetzee's picture
Forums: 

Hello

I would like to know how one measures the distance between two given TopoDS_Shapes.

And also how does one remove a TopoDS_Edge from a shape and update the shape?

Thanks for the help in advance.

Jacques Coetzee's picture

Should I use BRepExtrema_DistShapeShape for the distance calculation?

Jacques Coetzee's picture

Update: BRepExtrema_DistShapeShape works for the distance calculation.

Another question: How does one measure the length of a TopoDS_Wire?

Jacques Coetzee's picture

I used http://www.opencascade.org/org/forum/thread_9329/?forum=3 for the Wire length calculation.

Alexander Luger's picture

The length of a curve can be measured with GCPnts_AbscissaPoint::Length(mycurve). So extract all edges from the wire (TopExp_Explorer), get the curves behind the edges (BRep_Tool::Curve(edge)) and add the lengths of these curves together.

Alex

Jacques Coetzee's picture

Thank you Alex
I will definitely keep your solution in mind if my initial one fails.

Would you perhaps know how to remove a wire from a shape?

Jacques Coetzee's picture

I am currently reading http://www.opencascade.org/org/forum/thread_14101/?forum=3

I think it might have the solution.

Contact us

Attention: DO NOT use this form for all kind of request for the removal of your personal data. Please follow this link for such cases.