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.
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.
The problem turns out to be, when executing the (“Create composite curve using method : Composite” ) Composite command.
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.
After the initial nodes have been laid out the composite node is gotten from the library and linked into position.
As can be seen, we get a failure. However if one just takes one of the elements, a successful result can be obtained.
We can work with this to finish developing this translation, although this need some coding attention from the powers that be. (hint Autodesk)
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.
The script being rather long, can also be broken up to be more manageable.
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.
As usual, liberty was taken with color for visual interest. The files are available for downloading below.
Thanks for looking.