Quantcast
Channel: Scripting - McNeel Forum
Viewing all articles
Browse latest Browse all 5938

Polyline.IsClosed (API) Version 7.7.32

$
0
0

Previous to Version 7.7.32, we were working with defined shapes using vertex and face definitions. These shapes are formed successfully in other programs using mesh objects — converted to Breps.

For Rhino, we were using polylines to form mesh faces.

After 7.7.32, the same objects failed to form in Rhino. The problem seems to be a failure with IsClosed as applied to a Polyline object prior to conversion to a mesh face.

I’ve attached a test script (Python) including three objects. Two are derived from a simple box.

The box face data are as follows:

Data derived from Box created in Rhino:
Vertex Point
0 0, 200, 0
1 300, 200, 0
3 300, 0, 0
2 0, 0, 0
close 0, 200, 0

Data created by hand:
Vertex Point
3 300, 0, 0
2 300, 200, 0
1 0, 200, 0
0 0, 0, 0
close 300, 0, 0

These data sets represent opposite rotations (CW and CCW), but both sets are plainer and valid as Polylines that should rate as closed.

FulcrumPolylineTest_cmd.py (8.5 KB)

12 posts - 4 participants

Read full topic


Viewing all articles
Browse latest Browse all 5938

Trending Articles