Curve offset problem

I have a planar, non-self-intersecting, closed polyline curve.

When I use the Offset command in Rhino 7 or Rhino 6, it doesn’t work – I just get a microscopic polyline with two segments. This happens whichever side I offset, and even if I use a very small offset distance.



ProblemCurve.3dm (67.2 KB)

I originally created the curve by projecting a line onto a solid mesh, and I have had the same result with a few other curves created the same way. I used SetPt, Convert and CurveBoolean to make sure the curve is clean and flat, but none of that helped.

I tried using OffsetMultiple instead, and that caused Rhino 7 Mac to become unresponsive (I got a pinwheel cursor for >5min).

I understand that sometimes Offset needs a bit of help, but I can’t figure out what is problematic about this curve – as far as I can tell it is as simple as it looks!

Probably here:

Hello - the polyline is still pretty messy - some very short segments - you can try CleanUpPolyline or CleanUpPolyline in this plug-in - either one seems to help.

CurveCleanup.rhp (11.5 KB)

You’ll need to unblock the plug-in in Windows and then drag and drop it from where ever you saved it onto Rhino.
Oh, I don’t know if I have run this on Mac - here is a python script that does the same job- (1.9 KB)

To use the Python script use RunPythonScript, or a macro:

_-RunPythonScript "Full path to py file inside double-quotes"