i'm looking for the api to convert a spline to pline (autocad 2010 can do it with convert)
I hope exists also an api that we call to make it..
any idea ?
thanks in advance!
There is the Spline.ToPolylineWithPrecision Method.
How do you intend to recreate the path? I suppose recreating the Spline’s path with arcs would be a bit difficult – short line segments, however, should be fairly easy. If the spline’s total parameter (Interval) were divide by the appropriate amount:
Double seg = (Spline.EndParam – Spline.StartParam) / 100;
For example, then a for loop could find successive position with Spline.GetPointAtParameter. One characteristic of Splines is that the Interval naturally compresses at areas of high curvature so the chord height is kept to a minimal.