2010年5月25日 星期二

Chains_Pavilion ( RhinoScript )

運用RhinoScript做點小練習
稱之為Chains_Pavilion
We use RhinoScript for some practice
which is called Chains_Pavilion

首先先預先做好
一個單位的Pattern
再insert進到Rhino的另一新檔案中
First, we have to model a Block(or Pattern)
then save it,
and open a new Rhino file,
insert the Block you made before.

開啟新檔案後
必須先INSERT一遍
使得RHINO取得路徑
Inserting the Block is to make the Rhino
get the path where the Block located


然後開啟RhinoScript
運用INSERT的功能
可以複製陣列的單元
並可調整其長寬高比例(此例中沒有使用)
then open the RhinoScript
using the function of "insert"
to creat array elements.
We could also change the Scale and Rotation through this function

程式如下:
The program as following:

For k=1 To 3
  For j=1 To 3
     For i = 1 To 3
Call Rhino.InsertBlock("ger",Array(i*40,j*40,k*5),Array(-1,1,1),0)

'("要Insert的檔名", Insert的位置Array(x,y,z), Insert的XYZ比例Array( X,Y,Z), 轉動角度))
'("insert file name", insert location array(x,y,z), insert scale array(x,y,z), angle to rotate(angle))
      Next
  Next
Next

沒有留言:

張貼留言