How to trim a wire with UFrist and UEnd?

I get a wire ,and I want to trim the wire and get the segment of the wire between u1 and u2.
is there a way convert wire to curve or Directly split the wire into two segments?
Thanks in advance!

Mikhail Sazonov's picture

Look at the class BRepAdaptor_CompCurve.

Luke jk's picture

Thank you for your reply.
i know BRepAdaptor_CompCurve ::Trim(),but the result is not that i want,i want to get the TopoDS_Shape

Mikhail Sazonov's picture

It has the method Edge() that returns the edge with parameter that is needed to be split for the given U parameter. So, you can explore the wire in the order of its edges and construct the new wire within the given range.