parametric window tactile louvers (katie)

2008_11_161Option Explicit
‘Script written by <insert name>
‘Script copyrighted by <insert company name>
‘Script version Monday, November 17, 2008 12:19:20 AM

Call Main()
Sub Main()
 Dim i, j, arrPt, arrPt2, strCrv, strPath, strSrf, strPoint, arrPoint
 Dim arrPoints : arrPoints = Rhino.Getobjects 
 Call Rhino.EnableRedraw (False)
 For Each strPoint In arrPoints
  arrPoint = Rhino.PointCoordinates (strPoint)
  For j = 1 To 10
   For i = -180 To 180 Step 45
    arrPt = Rhino.Polar (arrPoint, i, j,Rhino.WorldYZPlane)
    strCrv = Rhino.AddLine (arrPt, Array(arrPt(0)-j/2,arrPt(1),arrPt(2)))
    arrPt2 = Rhino.Polar (arrPoint, i+90, j/1.5,Rhino.WorldYZPlane)
    strPath = Rhino.AddLine (arrPoint,arrPt2)
    strSrf = Rhino.ExtrudeCurve (strCrv, strPath)
    Call Rhino.MoveObject (strSrf,Rhino.CurveMidPoint (strPath),Rhino.CurveStartPoint (strPath))
    Call Rhino.DeleteObject (strPath)
 Call Rhino.EnableRedraw (True)
End Sub


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s