Hi Dale,
I’ve noticed a change in behavior when creating contours/sections through mesh objects between Rhino 6 and 7. Below is a simple command that cuts 9 sections through a sample mesh. When I run this in Rhino 6 I get 9 closed curves and their direction (cw vs ccw) is consistent. When I run this in Rhino 7 with the same model I get some closed curves and lots of curve pieces. Also on the closed curves the orientation is not consistent. Do you have any thoughts on what might be the cause? The mesh is valid and I’ve tried it on a few meshes with similar results. Thanks
I just want to let you know that I’ve debugged the origin of the problems, in fact, there are two:
some segments do not reconnect in the right order, and therefore a few pieces remain isolated. This is a problem of tolerances that are way too high when they arrive to the inner computations. RH-65835
the direction of the curves. Right now in V7, there was no convention for winding (ccw, right hand rule) and therefore the winding is accidental. RH-65833
I agree that the winding might be useful when intersecting planes, and therefore I am working on fixing it. Also, the tolerance issue can easily get fixed. I’m already working on these issues.
Thanks,
Giulio
–
Giulio Piacentino
for Robert McNeel & Associates giulio@mcneel.com
Hi @piac , Many thanks for looking into these. They are both quite important for Orca3D as they are used to compute the contained area of a planar intersection curve, and since the +/- sense of the area can be different (e.g., a closed area with a hole in it) the winding is also important. We’ll look forward to the update.
@piac, @dale I think this issue related to an inconsistent winding direction on sectioning a mesh via Mesh.CreateContourCurves has re-surfaced in Rhino 8. I am attaching a slightly modified file (deck surfaces removed) but using the same sample command (making the slight change to the CreateContourCurves to add the tolerance in the non-obsolete method). In Rhino 7 if I look at the resulting curve orientations they are consistent as below.
Would it be possible to implement the same consistent winding logic in Rhino 8/9 as you did in Rhino 7? Let me know if you are not able to reproduce this issue, thanks.