decompose a spline -> arcs / lines

Hi,

I'm looking for a API call that decomposes a spline into a set of arcs / line segments.
So far I haven't been able to find it... any ideas are much appreciated!

Thanks,

-jelle

Mikael Aronsson's picture

Do you need circular/elliptical arcs ? what is the requirements on the result (tolerance or something else) ?

You can use SplitBSplineCurve to split up a spline in smaller segments at specified parameters.

You might also find GeomConvert_BSplineCurveKnotSplitting useful.

You can of course use value(p) to split up the curve into linear line segments.

jelle's picture

Yes! GeomConvert_BSplineCurveKnotSplitting is what I've been looking for! Thanks Mikael

Forum supervisor's picture

Dear jelle,
You have already posted the same question in the thread http://www.opencascade.org/org/forum/thread_20706/ one month ago, and got many replies.
We ask you to behave and respect the rules of this forum
(see http://www.opencascade.org/org/forum/thread_1/ , " Attempts to re-post anything that was accepted less than 45 days ago will be treated as a duplicate.")
Regards
Forum supervisor

jelle's picture

Sorry supervisor, your right...