You don't need the formula..
Just draw your spline into a GraphicsPath. Flatten the Path using the
Flatten method and then extract the points from the GraphicsPath object
directly.

Signature
Bob Powell [MVP]
Visual C#, System.Drawing
Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm
Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm
All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.
> Hi everyone
> I need to know the formula used in .net for the cardinal spline since i need
> to generate an array of values of the curve after drawing it.
>
> Thanks
Lazarus Lang - 26 Nov 2004 13:14 GMT
> You don't need the formula..
>
> Just draw your spline into a GraphicsPath. Flatten the Path using the
> Flatten method and then extract the points from the GraphicsPath object
> directly.
That's right but if for some other reason you (the OP, that is) DO need the
formulae, I can only advise to buy Charles Petzold's excellent book called
"Windows Programming with C#" (or the newer VB.NET variant) which
contains an entire section on this exact subject. Heck, you can
probably download the source code on his web site (Google !).
eltwo