A playground for University of Bologna Students and a 6-days seminar about digital tools.

Digital generative tools are a very important part of architectural education. Andrew Kudless during his conference at SimAE was telling about chinese traditional woodcraftsmen: they spend their first two years of apprentice in making their own tools. Today, we have a large pool of digital ready made tools, built to respond to more or less specific problems or tasks, while keeping a level of flexibility and personalization. The majority of these tools have hidden capabilities, which can only be accessed bypassing the conventional interface and getting close to the machine logic of programming or building parametric components which generate shapes. Thus, seriality, differentiation, complexity can be implemented in architectural projects through code, in order to exploit the power of algorithmic based complex systems which are the basis of biological systems.


But, before going through such complexity, we must start with simple tasks and simple rules. Before playing seriously we need practice. This is the playground where a bunch of students will start to practice, a pool where they will share their results and questions. Maybe the stuff here that will be posted will seem obvious or naive to the navigated code-monkey, but, as I mentioned before, we all start from the basics and this is intended as a place to start. However, any comment and contribution is appreciated.

Playground is open, let's play! _ Alessio

13.4.09

Easter Egg



This is just for laughs, nothing serious, ok? Had some fun doing this small Easter Script.

1. Create a sphere in Rhino and stretch its control points to turn it into an egg

2. run the script below

3. Happy Easter!

Here's the script:

Option Explicit

'
'
'
' . Easter Stripe Egg
' . script written by Alessio Erioli
' .
' . v. 12 April 2009 + 22:05:27
' . © Alessio Erioli
' . monkey Rulez, so play by the rulez.
'____________________________________________________________________________________

Call Easteregg()

Sub Easteregg()

' input surface and division intervals

Dim strSurf: strSurf=Rhino.GetObject("select a surface",8)

' vertical subdivision intervals (<=200, otherwise sweep fails)

Dim intVInt: intVInt=Rhino.GetInteger("n. of V intervals?",200,10)

'lights off!

Rhino.EnableRedraw False

' get surface domain (u and v)

Dim arrUdom,arrVdom, zminPt, zmaxPt

arrUdom = Rhino.SurfaceDomain(strSurf,0)

arrVdom = Rhino.SurfaceDomain(strSurf,1)

' get zmin and zmax points

zminPt=Rhino.EvaluateSurface(strSurf,array(arrUdom(0),arrVdom(0)))

zmaxPt=Rhino.EvaluateSurface(strSurf,array(arrUdom(0),arrVdom(1)))

Dim i, inc, angInc, ang, arrPt, arrPt2, vect, strCrv

Dim arrPts: ReDim arrPts(intVint)

' hetght and angle increments

inc = (zmaxPt(2)-zminPt(2))/intVint

angInc = 180/5

ang = 0

For i = 0 To IntVint

' point along vertical

arrPt= array (zminPt(0),zminPt(1),zminPt(2)+(i*inc))

' second point for vector construction

arrPt2 = array (zminPt(0)+1,zminPt(1),zminPt(2)+(i*inc))

' vector construction and rotation

vect= Rhino.VectorCreate(arrPt, arrPt2)

vect=Rhino.VectorRotate(vect,ang+i*angInc,array(0,0,1))

' projects point to surface

arrPts(i)=Rhino.ProjectPointToSurface(arrPt,strSurf, vect)(0)

If Isnull(arrPts(i)) Then

arrPts(i)=arrPt

End If

Next

' create base curve

strCrv = Rhino.AddInterpCurve(arrPts,3)

Dim arrPlane,arrCircles, dblrad

ReDim arrCircles(intVint)

' create circular sections along curve

For i=0 To intVint

arrPlane=Rhino.CurvePerpFrame(strCrv,Rhino.CurveClosestPoint(strCrv,arrPts(i)))

dblrad=sin(i*pi/intVint)+0.001

arrCircles(i)=Rhino.AddCircle(arrPlane,dblrad)

Next

' add a sweep 1 rail surface

Call Rhino.Addsweep1(strCrv, arrCircles)

' hide unnecessary elements

Rhino.HideObject strCrv

Rhino.HideObject strSurf

Rhino.HideObjects arrCircles

' lights on!

Rhino.EnableRedraw True

End Sub

No comments:

Post a Comment