random.random() #gives a float number between 0 and 1 to get random number between
#two numbers then multiply by the highest number you want
a = 5
points = []
for i in range(0,40):
x = a * sin(pi/2*i) #to make it smaller then divide a*100/(i+1)
y = a * cos(pi/2*i)
z = i
points.append([x,y,z])
divisions = 20
evaluationpoints = []
curve = rs.AddCurve(points)
rotatedcurves = []
numberofcurves = 2
for i in range(0,5): #put 5 curves inside of list and rotated
rotatedcurves.append(rs.RotateObject(curve,[0,0,0],360/numberofcurves*i,None,True))
radius = 1
for j in range (0,len(rotatedcurves)):
circles = []
for i in range(divisions):
parameter = i/ divisions
evaluationparm = rs.CurveParameter(rotatedcurves[j], parameter)
perpframe = rs.CurvePerpFrame(rotatedcurves[j],evaluationparm)
rs.AddCircle(perpframe, radius)
circles.append(rs.AddCircle(perpframe, radius+i/4))
rs.AddLoftSrf(circles)
No comments:
Post a Comment