ProjectToCPlane refusal


ProjectToCplane refuses to project the curve in the attached to WorldXY. This is because it would produce a “bad object” - I assume one of the small segments is sufficiently vertical to produce a zero or near-zero length segment.

But, SetPt to Z0 does work - I get a “bad object” warning, but it produces a curve which I can simply explode/rejoin to produce a valid object. Funny, plain old Project to a planar surface at Z0 doesn’t even produce a bad object… But it’s not quite the same curve.

Perhaps I’m being utopian here, but I would like Rhino to try eliminating the vertical or near-vertical segments in order to produce a valid projection to CPlane. This would be practical in a lot of cases.

Thanks, --Mitch

NoProject.3dm (92.9 KB)

(David Cockey) #2

Exploding the polyline, using ProjectToCPlane on the individual lines (70 lines do not project), and using Join on the projected lines results in a closed polyline. That should be simple process to automate for polylines.


Yep, that’s why I think the functionality it should be included in the Rhino command.

(David Cockey) #4

ProjectToCPlane works on degree 3 curves with vertical segments, and even on vertical lines which are degree 3 curves. For the straight line case the resulting object can’t be seen (it does not show as a point) but can be found. (Added) The projected straight line has zero length but is not identified as a bad object by SelBadObjects

(Pascal Golay) #5

Hi Mitch - added to the heap. Looks like you can, for now, shortcut your process with testCleanPolyline on the SetPt output, or, as you’re probably doing, Polyline.DeleteShortSegments().



That’s a new one… Thanks. :smile:

(David Cockey) #7

@pascal ProjectToCPlane for NURBS curves with vertical segments results in a curve with stacked control points. The result is a valid object, not a bad object. Is there a command to either convert a curve with stacked control points to an identical multiknot curve, or to explode a curve with stacked control points at the stacked control points?

ProjectToCPlane for a NURBS curve which is a vertical line results in a zero lengh curve with stacked control points. The result is a valid object, not a bad object. The resulting curve is invisible but the curve can be selected with a crossing box and the control points can be made visible. It may be helpful to convert zero length NURBS curves to a single point object.

File with examples of both situations: Deg3PTCP.3dm (29.5 KB)

(Pascal Golay) #8

Hi David - thanks for the examples - I do not know of any tools that will fix the collapsed points NURBS case. testValidateControlPointSpacing will show you where there could be problems and where to split up the curve and SimplifyCrv, but nothing all bundled up that I know of.