NURBS 2 Spline
Submitted by Alexander E. Bicalho on Fri, 2006-10-20 19:45.
Tagged with terms:
Date Updated:
04/22/2000Converts NURBS curves in Spline Shapes.
Version Requirement:
3Homepage URL:
http://www.origamy.com.br/Download URL:
http://www.origamy.com.br/max/mxs3/nurbs2spline.mcr
very ok
very ok
To correct the bug of your
To correct the bug of your algorithm use my simple method.
(You should reverse your order of node creation!)
Here is a question Why the program is working only on the CVcurves and it is not working on the POINTcurves?
OBJ = selection[1]
NS = getnurbsset OBJ #relational
sp = splineshape()
for i = 1 to NS.numobjects do(
minv = NS[i].parameterrangemin
maxv = NS[i].parameterrangemax
addnewSpline sp
for j = 0.0 to 1.0 by 0.1 do(
addknot sp i #smooth #curve (evalpos NS[i] (((maxv - minv) * j) + minv))
)
if NS[i].isclosed then close sp i
)
sp.rotation = OBJ.rotation
sp.scale = OBJ.scale
sp.pos = OBJ.pos
Updateshape sp