Tag Archives: Sina Mesdaghi


Sina Mesdaghi

Therese Diede

Call Main()
Sub Main()
Dim i,j,d,k,p,q,u,v, arrPlane, Circle, strAttractor, strPath, extrude, arrPoint, arrPoints, intLoop, arrRndNumber, strPoints()
Dim UDomain, VDomain, UStep, VStep, dblDistance, arrAttractor, testDistance
Dim intU : intU = 100 ‘Horizontal
Dim intV : intV = 1 ‘Vertical
ReDim arrCrvPt(intU)
ReDim arrCrv(intV)
ReDim arrFrame(intU,intV)
ReDim arrPts(intU,intV)
ReDim arrPtNormal(intU,intV)
Dim dblMatThick : dblMatThick = 0.25
For q = 0 To 4
For p = 1 To 5
arrPlane = Rhino.PlaneFromPoints (Array(p*8,q*8,0), Array(p*8,q*8+1,0), Array(p*8+1,q*8,0))
circle = Rhino.AddCircle (arrPlane, 3.5)
strPath = Rhino.AddLine (Array(20,30,0), Array(20,30,dblMatThick/2))
extrude = Rhino.ExtrudeCurve (circle, strPath)
arrPoints = Rhino.DivideCurve (circle,(4+p*4))
intLoop = Random(0+p*3, UBound(arrPoints))
If intLoop < 2 Then intLoop = 2
For j = 0 To IntLoop
ReDim Preserve strPoints(j)
arrRndNumber = Random(0, UBound(arrPoints))
arrPoint = arrPoints(arrRndNumber)
strPoints(j) = Rhino.AddPoint (arrPoint)
ReDim arrAttractors(UBound(strPoints))
d = (p+2)*20
For Each strAttractor In strPoints
arrAttractors(k) = Rhino.pointcoordinates (strAttractor)
UDomain = Rhino.SurfaceDomain(extrude, 0)
VDomain = Rhino.SurfaceDomain(extrude, 1)
UStep = (UDomain(1) – UDomain(0)) / intU
VStep = (VDomain(1) – VDomain(0)) / intV
For j = 0 To intV
For i = 0 To intU
u = UDomain(0) + UStep * i
v = VDomain(0) + vStep * j
arrFrame(i,j) = Rhino.SurfaceFrame (extrude, Array(U,V))
dblDistance = d
For Each arrAttractor In arrAttractors
testDistance = Rhino.Distance (arrFrame(i,j)(0), arrAttractor)
If testDistance < dblDistance Then
dblDistance = testDistance
End If
dblDistance = dblDistance/1
arrPtNormal(i,j) = Rhino.PointAdd(arrFrame(i,j)(0), Rhino.VectorScale (arrFrame(i,j)(3),dblDistance+(j*0.5)))
arrCrvPt(i) = arrPtNormal(i,j)
arrCrv(j) = Rhino.AddCurve (arrCrvPt)
Call Rhino.addLoftSrf (arrCrv)
Call Rhino.DeleteObjects (strPoints)
Call Rhino.DeleteObject (extrude)
Call Rhino.addLoftSrf (Array(circle,arrCrv(0)))
Call Rhino.SelectObject (arrCrv(1))
Call Rhino.Command (“PlanarSrf “)
Call Rhino.UnselectAllObjects
Call Rhino.MoveObject (circle, Array(0,0,0),Array(0,0,dblMatThick+0.1))
Call Rhino.OffsetCurve (circle, Array(0,0,0), 0.125)
Call Rhino.deleteObject (circle)
Call Rhino.deleteObjects (arrCrv)


End Sub

Function Random(nMin, nMax)
Random = Int((nMax – nMin)*Rnd + nMin)
End Function



sina – week one mod

Option Explicit
Script written by <sina>
Script version Tuesday, October 28, 2008 11:25:26 PM

Call Main()
Sub Main()
Dim arrPlane, i, j, strCrv(), strInnerCrv(), strSrf1, strSrf2, arrLftSrf1, arrLftSrf2, arrLftSrf3
For j = 0 To 10
For i = 0 To 15
ReDim Preserve strCrv(i)
ReDim Preserve strInnerCrv(i)
arrPlane = Rhino.PlaneFromPoints (array(0,j*25,i*(j+1)), array(1,j*25,i*(j+1)), array(0,j*25+1,i*(j+1)))
If i < j+3 Then
strCrv(i) = Rhino.AddCircle (arrPlane, 5.0)
strInnerCrv(i) = Rhino.AddCircle (arrPlane, 4.0)
If i = 0 Then
Call rhino.MoveObject (strInnerCrv(i),array(0,0,0),array(0,0,1))
End If
strCrv(i) = Rhino.AddCircle (arrPlane, 10.0)
strInnerCrv(i) = Rhino.AddCircle (arrPlane, 9.0)
End If
If i = 0 Then
strSrf1 = Rhino.AddPlanarSrf (strCrv)
strSrf2 = Rhino.AddPlanarSrf (strInnerCrv)
End If
If i = 10 Then
arrLftSrf1 = Rhino.AddLoftSrf (array(strCrv(i),strInnerCrv(i)))
End If
If j > i+3 Then
strCrv(i) = Rhino.AddCircle (arrPlane, 5.0)
strInnerCrv(i) = Rhino.AddCircle (arrPlane, 4.0)
End If

arrLftSrf2 = Rhino.AddLoftSrf (strCrv,,,1)
arrLftSrf3 = Rhino.AddLoftSrf (strInnerCrv,,,1)
Call Rhino.JoinSurfaces (array(arrLftSrf1(0),arrLftSrf2(0),arrLftSrf3(0),strsrf1(0),strsrf2(0)),True)
Call Rhino.deleteobjects (strCrv)
Call Rhino.DeleteObjects (strInnerCrv)
End Sub

final project proposal

We have two ideas for a final project.

1. First is to write a script for the prototype urban fabric with parameters related to light, relationship between buildings, and parkspace. The final project would be a 1:250 model of the urban fabric. The material would be 3-D printed plastic plus laser-cut plexiglass for hybrid circulation.

2. Second is to script a set of kitchen table ware, morphing a plate into a bowl into a cup into a wine glass.