Drawing Splines, 2
Method 2: recursive subdivision - vary step size to draw short lines
Subdivide(u0,u1,maxlinelength)
umid = (u0 + u1)/2
x0 = F(u0)
x1 = F(u1)
if |x1 - x0| > maxlinelength
Subdivide(u0,umid,line)
Subdivide(umid,u1,line)
else drawline(x0,x1)
- Method 3: forward differences - rearrange terms to eliminate multiplies
- Variant on Method 2 - subdivide based on curvature
- replace condition in “if” statement with straightness criterion
- draws fewer lines in flatter regions of the curve