Monthly Archives: March 2014

DesignScript Curve Translation, Curve.CoordinateSystemAtEqualArcLength.UpVector#3 – Code to Node to Code

Hi Everyone:

This the third curve file in a series of forty-nine DS translations. The file, “Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector”  can be accessed from the DesignScript Editor (DSE) Sample files, which are shown below and are on the DSE opening page.

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector.ds

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector.ds

After copying the sample file from the DSE and moving it into DesignScript Studio (DSS), it will have a similar node layout as shown below. This is very similar to the previous DSE file.

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3

Once again the graph nodes are translated further from the script.

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3a

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3a

After the translation is complete the “Node to Code” operation is executed.

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3b

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3b

Again this file was straightforward and not requiring further editing. The resulting Graphic is generated from the file.

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3-Graphic Window

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3-Graphic Window

The files can be downloaded from the links below.

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3a

Geometry.Curve.CoordinateSystemAtEqualArcLength.UpVector#3b

Thanks for looking.

T!M

DesignScript Curve Translation, Curve.CoordinateSystemAtParameter.UpVector #2 – Code to Node to Code

Hi Everyone:

This the second, in a series of forty-nine curve file translations. The file, Geometry.Curve.CoordinateSystemAtParameter.UpVector is from the DesignScript Editor (DSE) Sample files.

Geometry.Curve.CoordinateSystemAtParameter.UpVector.ds#2

Geometry.Curve.CoordinateSystemAtParameter.UpVector.ds#2

This file, other than word “Geoemtry“,  which we have decided is not a new Math, is fine with no anomalies. After copying the sample file from the DSE and moving it into DSS, we can quickly get a canvas looking similar to the one below.

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

After which the graph nodes can be further defined and their properties developed.

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

As shown above, the various types of properties of the nodes are shown in their respective groupings. Satisfied with the translation the “Node to Code” operation is executed.

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

Again this file was quite straightforward without any editing required. The resulting Windows Graphic from the files is shown below.

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

The files can be downloaded from the links below.

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2a

Geometry.Curve.CoordinateSystemAtParameter.UpVector#2b

Thanks for looking.

T!M

DesignScript Curve Translation, Curve.Composite#1 – Code to Node to Code

Hi Everyone:

This the first in a series of forty-nine curve file translations. The file, Geometry.Curve.Composite.ds is from the DesignScript Editor (DSE) Sample files.

Geometry.Curve.Composite.ds#1

Geometry.Curve.Composite.ds#1

The first thing to note is that Geoemtry” is not really a new branch of Math, just a misspelling, which at some point hopefully gets corrected. More importantly though is the error this file generates when run in the DSE.

Geometry.Curve.Composite.ds_error

Geometry.Curve.Composite.ds_error

The problem turns out to be, when executing the (“Create composite curve using method : Composite” ) Composite command.

Geometry.Curve.Composite.ds- Error highlighted

Geometry.Curve.Composite.ds- Error highlighted

Note the highlighted “Composite curve operation failed” statement after which the “Deferencing a non-pointer  warning is given for the remainder of the script.

One can investigate this error in node form, but first the preliminary translation to DesignScript Studio is required.

Geometry.Curve.Composite.ds#1

Geometry.Curve.Composite.ds#1

After the initial nodes have been laid out the composite node is gotten from the library and linked into position.

Geometry.Curve.Composite#1-error

Geometry.Curve.Composite#1-error

As can be seen, we get a failure. However if one just takes one of the elements, a successful result can be obtained.

Geometry.Curve.Composite#1-error_solution

Geometry.Curve.Composite#1-error_solution

We can work with this to finish developing this translation, although this need some coding attention from the powers that be. (hint Autodesk)

Geometry.Curve.Composite#1a

Geometry.Curve.Composite#1a

Sticking with just the mySpline node as the operator for the Curve.Composite node we are able to extract the other specified properties. Satisfied, as much as possible with the translation thus far, the “Node to Code” translation can be initiated.

Geometry.Curve.Composite#1b

Geometry.Curve.Composite#1b

The script being rather long, can also be broken up to be more manageable.

Geometry.Curve.Composite#1b

Geometry.Curve.Composite#1b

Among all the anomalies in the script, the above middle stand-alone coordinate Point2 doesn’t figure to really have a purpose. With that said the relatively simple Window Graphic that is generated from this visual code is shown below.

Geometry.Curve.Composite_Windows Graphic

Geometry.Curve.Composite_Windows Graphic

As usual, liberty was taken with color for visual interest. The files are available for downloading below.

Geometry.Curve.Composite#1

Geometry.Curve.Composite#1a

Geometry.Curve.Composite#1b

Thanks for looking.

T!M

DesignScript Curve Translation, Curve.Line.IsParallel#4 – Code to Node to Code

Hi Everyone:

This is the last of the Line file, Geometry.Curve.Line.IsParallel#4, in a series of four curve- line translations, from the DesignScript Editor Sample files.

Geometry.Curve.Line.IsParallel.ds#4

Geometry.Curve.Line.IsParallel.ds#4

The highlighted line file is shown in the DesignScript Editor. Open the Editor and copy the code.

Geometry.Curve.Line.IsParallel#4

Geometry.Curve.Line.IsParallel#4

Open DesignScript Studio, then paste the code into the canvas. The initial  translation will look something like below.

Geometry.Curve.Line.IsParallel#4a

Geometry.Curve.Line.IsParallel#4a

The properties are highlighted for their attributes. TheNode to Code translation can now take place.

Geometry.Curve.Line.IsParallel#4b

Geometry.Curve.Line.IsParallel#4b

The graphic from the file(s) is shown below.

Geometry.Curve.Line.IsParallel#4 Graphic Window

Geometry.Curve.Line.IsParallel#4 Graphic Window

The files can be downloaded from the links below.

Geometry.Curve.Line.IsParallel#4

Geometry.Curve.Line.IsParallel#4a

Geometry.Curve.Line.IsParallel#4b

Thanks for looking.

T!M

 

DesignScript Curve Translation, Curve.Line.IsColinear#3- Code to Node to Code

Hi Everyone:

This is the third Line file, Geometry.Curve.Line.IsColinear.dsin a series of four curve- line translations from the DesignScript Editor Sample files.

Geometry.Curve.Line.IsColinear.ds

Geometry.Curve.Line.IsColinear.ds

The highlighted file, Geometry.Curve.Line.IsColinear.ds is shown in the DSE (DesignScript Editor). Copy the resulting script to the clipboard and then open DSS (DesignScript Studio). Paste the script from the clipboard into the blank canvas. Develop the translation and it will look something like below.

Geometry.Curve.Line.IsColinear#3

Geometry.Curve.Line.IsColinear#3

Note the how the properties are developed in a sequence.

Geometry.Curve.Line.IsColinear#3a

Geometry.Curve.Line.IsColinear#3a

The “Node to Code” translation can now take place.

Geometry.Curve.Line.IsColinear#3b

Geometry.Curve.Line.IsColinear#3b

The graphic generated from the files is shown below.

Geometry.Curve.Line.IsColinear- Windows Graphic

Geometry.Curve.Line.IsColinear- Windows Graphic

The files can be downloaded from the links below.

Geometry.Curve.Line.IsColinear#3

Geometry.Curve.Line.IsColinear#3a

Geometry.Curve.Line.IsColinear#3b

Thanks for looking.

T!M

DesignScript Curve Translation, Line.StartPointEndPoint#2- Code to Node to Code

Hi Everyone:

This is the second Line file, Curve.Line.ByStartPointEndPoint, in a series of four curve- line translations from the DesignScript Editor Sample files.

Geometry.Curve.Line.StartPointEndPoint.ds

Geometry.Curve.Line.ByStartPointEndPoint.ds

Pick the highlighted file in he editor (DSE), open it and copy the script, then open (DesignScript Studio) DSS and paste the script into a new canvas. Develop the translation.

Geometry.Curve.Line.StartPointEndPoint#2a

Geometry.Curve.Line.ByStartPointEndPoint#2

Note the sequence of properties that the line node commands as illustrated and shown below.

Geometry.Curve.Line.StartPointEndPoint#2a

Geometry.Curve.Line.ByStartPointEndPoint#2a

Execute the “Node to Code” and translate the graph canvas to the script as shown below.

Geometry.Curve.Line.StartPointEndPoint#2b

Geometry.Curve.Line.ByStartPointEndPoint#2b

A small portion of the highlighted script is edited as shown.

Geometry.Curve.Line.StartPointEndPoint#2b

Geometry.Curve.Line.BYStartPointEndPoint#2b

This makes for a more compact code. The resulting Graphic from  Curve.Line.ByStartPointEndPoint is shown below.

Curve.Line.ByStartPointEndPoint

Curve.Line.ByStartPointEndPoint

The files are available for download from the links below.

Geometry.Curve.Line.StartPointEndPoint#2

Geometry.Curve.Line.StartPointEndPoint#2a

Geometry.Curve.Line.StartPointEndPoint#2b

Thanks for looking.

T!M

DesignScript Curve Translation, Line.StartPointDirectionLength#1- Code to Node to Code

Hi Everyone:

This is the first Line file, Curve.Line.StartPointDirectionLength, in a series of four curve- line translations from the DesignScript Editor Sample files.

Curve.Line.StartPointDirectionLength.ds

Curve.Line.StartPointDirectionLength.ds

Pick the highlighted file, open it and copy the script, then open DSS (DesignScript Studio) and paste the code into the blank canvas. The initial and essential translation will look something like below.

Curve.Line.StartPointDirectionLength#1

Curve.Line.StartPointDirectionLength#1

After defining the additional properties the graph Canvas will include the additional node definitions as shown below.

Geometry.Curve.Line.StartPointDirectionLength#1a

Geometry.Curve.Line.StartPointDirectionLength#1a

The highlighted properties show the various groupings above. The node to code operation is then executed and the resulting script is shown below.

Geometry.Curve.Line.StartPointDirectionLength#1b

Geometry.Curve.Line.StartPointDirectionLength#1b

Geometry.Curve.Line.StartPointDirectionLength#1b-graphic

Geometry.Curve.Line.StartPointDirectionLength#1b-graphic

A little cleanup is conducted to created a more compact script.

The resulting graphic is generated from the files.

Geometry.Curve.Line.StartPointDirectionLength#1Windows graphic

Geometry.Curve.Line.StartPointDirectionLength#1Windows graphic

The files are available for downloading below.

Geometry.Curve.Line.StartPointDirectionLength#1

Geometry.Curve.Line.StartPointDirectionLength#1a

Geometry.Curve.Line.StartPointDirectionLength#1b

Thanks for looking.

T!M

DesignScript Curve Translation, Circle.ByCenterPointsOnCurve#4- Code to Node to Code

Hi Everyone:

This is the forth circle file, Circle.BytwoPointsNormal, the last curve – circle file in a series of four translations.

Geometry.Curve.Circle.ByTwoPointsNormal.ds#4-Graphic

Geometry.Curve.Circle.ByTwoPointsNormal.ds#4-Graphic

Copy and paste the script from the DSE to the DSS canvas. Translate the initial code to get a similar view as shown below.

Geometry.Curve.Circle.ByTwoPointsNormal#4

Geometry.Curve.Circle.ByTwoPointsNormal#4

After these central nodes are sufficiently defined, the specific properties of curve-geometry are extrapolated.

Geometry.Curve.Circle.ByTwoPointsNormal#4a

Geometry.Curve.Circle.ByTwoPointsNormal#4a

The property variations that extend from the Circle.ByTwoPointsNormal node are outlined above.

Geometry.Curve.Circle.ByTwoPointsNormal#4b

Geometry.Curve.Circle.ByTwoPointsNormal#4b

As highlighted above in the “Node to Code” translation, the Variable can be simplified and named as shown below.

Geometry.Curve.Circle.ByTwoPointsNormal#4b

Geometry.Curve.Circle.ByTwoPointsNormal#4b

Geometry.Curve.Circle.ByTwoPointsNormal#4-Windows Graphic

Geometry.Curve.Circle.ByTwoPointsNormal#4-Windows Graphic

The resulting graphic is shown above and the files are available for downloading below.

Geometry.Curve.Circle.ByTwoPointsNormal#4

Geometry.Curve.Circle.ByTwoPointsNormal#4a

Geometry.Curve.Circle.ByTwoPointsNormal#4b

Thanks for looking.

T!M

DesignScript Curve Translation, Circle.ByCenterPointsOnCurve#3– Code to Node to Code

Hi Everyone:

This is the third circle file, Circle.ByCenterPointsOnCurve, in a series of four circle translations.

Geometry.Curve.Circle.ByPointsOnCurve.ds#3-Graphic

Geometry.Curve.Circle.ByPointsOnCurve.ds#3-Graphic

After copying and pasting the script from the DSE to DSS’s blank canvas and translating the initial code one gets a graph node canvas similar to below.

Geometry.Curve.Circle.ByPointsOnCurve#3

Geometry.Curve.Circle.ByPointsOnCurve#3

Before continuing the translation, the inputs to the nodes are defined further.

Geometry.Curve.Circle.ByPointsOnCurve#3

Geometry.Curve.Circle.ByPointsOnCurve#3

Satisfied with the extent of the nodes definitions, one develops the various  properties that are unique to the circle-curve-geometry. Note the variations that extend from the Circle.ByCenterPointsOnCurve node as highlighted and indicated below.

Geometry.Curve.Circle.ByPointsOnCurve#3a

Geometry.Curve.Circle.ByPointsOnCurve#3a

Ensure that all nodes are adequately defined before executing the “Node to Code” operation.

Geometry.Curve.Circle.ByPointsOnCurve#3b

Geometry.Curve.Circle.ByPointsOnCurve#3b

Noting the Variablecould be edited on the script as highlighted, the change is made as indicated below.

Geometry.Curve.Circle.ByPointsOnCurve#3b-Graphic

Geometry.Curve.Circle.ByPointsOnCurve#3b-Graphic

The resulting Windows graphic is shown below.

Geometry.Curve.Circle.ByPointsOnCurve-Windows Graphic

Geometry.Curve.Circle.ByPointsOnCurve-Windows Graphic

The files are available for downloading below.

Geometry.Curve.Circle.ByPointsOnCurve#3

Geometry.Curve.Circle.ByPointsOnCurve#3a

Geometry.Curve.Circle.ByPointsOnCurve#3b

Thanks for looking.

T!M

DesignScript Curve Translation, Circle.ByCenterPointRadiusNormal#2– Code to Node to Code

Hi Everyone:

This is the second circle file,Curve.Circle.ByCenterPointRadiusNormal, in a series of four circle translations.

Geometry.Curve.Circle.ByCenterPointRadiusNormal.ds#2-graphic

Geometry.Curve.Circle.ByCenterPointRadiusNormal.ds#2-graphic

The DSE (Editor) sample file list on the opening page shows the file ”Curve.Circle.ByCenterPointRadiusNormal.ds.  Open it in the editor and copy the resulting code.  Then, open DSS (DesignScript Studio) and paste the code into the blank canvas.

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2

Do the essential translation by selecting the appropriate Nodes from the Library. Then continue on and generate the rest of them from the context menu located on the circle node.

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2a

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2a

After all the code is translated into nodes, enact the “Code to Node” process by creating a pick box around all the nodes on the canvas and select the context menu in the upper right corner of the selection box.

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2b

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2b

A little editing maybe desired on the Variable as highlighted above. Edit the two lines into one as shown below.

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2b-graphic

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2b-graphic

Find the resulting Windows graphic that’s generated from each of the translations.

Geometry.Curve.Circle.ByCenterPointRadiusNormal -Windows graphic

Geometry.Curve.Circle.ByCenterPointRadiusNormal -Windows graphic

The files are available for downloading in the links below.

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2a

Geometry.Curve.Circle.ByCenterPointRadiusNormal#2b

Thanks for looking.

T!M