Wednesday, June 10, 2009

02 B - Valentina De León



import maya.cmds as cmds
from math import*
from random import*
#creating the curve
def curves (amplitude):
numPoints= 40
points=[]
#loop
for i in range (1,numPoints,1):
#function of the spiral curve:
x=sin(i)*amplitude
y=cos(i)*amplitude/30
z= i
myPoint= (x,y,z)
#points in the list
points.append(myPoint)
myCurve=cmds.curve(d=30, p=points)
return myCurve
#list to store the curves
myCurve=[]
numCurves=70
#function
for i in range(0,numCurves,5):
crv= curves (i)
myCurve.append (crv)
print crv
#moving the curves
cmds.move (45,70,35, crv)
cmds.loft(myCurve)

No comments:

Post a Comment