#DesignScript -Geometry.ImportFromSat#2 – Code to Node to Code

This is the second of six DesignScript translations, from the geometry category of the DS Editor (DSE) Samples.

Geometry.ImportFromSat-ds#2

Open the file Geometry.ImportFromSat.ds in the DS Editor and run it. The script is shown below.

Geometry.ImportFromSat.ds#2

Remember the last translation in which we exported a cube, entitled Geometry.ExportFromSat.ds? Well we are going to use that as the file we import for this translation instead of the flower file. The reason for that is primarily that the flower file is rather large and the computer I’m currently using for this is somewhat overwhelmed by it.

Go to the last file and save it to the root Directory where the file is saved and place it there.

Now open DS Studio, copy & paste the DSE script, Geometry.ImportFromSat.ds into a blank canvas. Edit the script and replace “flower.sat” for “cube.sat”, also make sure that flower = is replaced with cube = .

Geometry.ImportFromSat#a2-alt

Note the highlighted commenting out which must be deleted in order to activate the code.

Geometry.ImportFromSat#a2-alt-edited

Now comment out the “(import(ProGeometry.dll)” script. It can now be run as a Code Block of script, before the translation to Nodes takes place.

Geometry.ImportFromSat#2-alt

The preliminary translation is shown above, while the developed translation is shown below.

Geometry.ImportFromSat#2a-alt

The red and yellow highlighted areas match the description and properties layout that is given to the script in the initial DS Editor *.ds file.

Geometry.ImportFromSat#2b

The “Node to Code” operation as shown above. A little editing is desired.

Geometry.ImportFromSat#2b-edited

The Geometry that is generated from the operation is shown below. Color was added for interest.

Geometry.ImportFromSat#2-Graphic Window

DSS was run as a stand-alone application and the translation files are available to download from the DropBox links below.