Quantcast
Channel: Scripting - McNeel Forum
Viewing all articles
Browse latest Browse all 4125

RhinoPython rs.Command("_-Helix

$
0
0

David wrote:

Hi guys,
Unable to find anything in RP with regard to creating a helix using scripting so
have to use rs.Command. The inputs for the start and end of the helix axis, along
with a point positioning the helix radius, seem ok but cannot input the pitch and number of
turns.

import rhinoscriptsyntax as rs
import math
import Rhino
import System

Helix_Length = 20.0
Helix_Radius = 3.0
Helix_Pitch = 2.0
Helix_Turns = Helix_Length/Helix_Pitch
Axis_StartPt = rs.AddPoint(0,0,0)
Axis_EndPt = rs.AddPoint(Helix_Length,0,0)
Pt_1 = rs.AddPoint(0,Helix_Radius,0)

Helix_Path = rs.Command("-Helix selid " + str(AxisStartPt) + " selid " +str(Axis_EndPt) + " selid " + str(Pt_1) + " _Enter _Enter ")

RP does not ask for the pitch or the number of turns NOR are the default values use.
Thus no helix!

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 4125