A cardinal spline is a sequence of individual curves joined to form a larger curve. The spline is specified by an array of points and a tension parameter.
The following illustration shows a set of points and a cardinal spline that passes through each point in the set.
To draw a cardinal spline, you need a Graphics object, a Pen object, and the third parameter is a tension.
Call DrawCurve method to draw a cardinal spline. The Pen object, array of point, and tension are passed as arguments.
The following is the syntax of DrawCurve method:
| DrawCurve(ByVal pen As System.Drawing.Pen, ByVal points() As System.Drawing.Point, ByVal tension As Single) |
The following code example demonstrates how to draw a cardinal spline: