class wmutil.CubicCurve
Available on all platforms
Catmull-Rom method to draw smooth curve
See http://www.t-pot.com/program/2_3rdcurve/index.html for detail. (written in japanese)
General formula of smooth curve from x0 to x_(n+1) through x1 ... xn is x(t) = a * t^3 + b * t^2 +c * t + d.
Instance Fields
function new(p0:Point3D, p1:Point3D, p2:Point3D, p3:Point3D):Void
Constructor. If positions are given, Catmull-Rom curve associated with those points will be generated. See also generate() function.
function generate(p0:Point3D, p1:Point3D, p2:Point3D, p3:Point3D):CubicCurve
generate Catmull-Rom curve. First OR last argument can be null, it is
necessary in drawing curves on terminals. The return value is the
this
instance itself.