generative modeling for Rhino
I'm having a problem offsetting a polyline: when the offset segments form convex corners, new corner points are created and I can't find a way to eliminate them.
Note: I can't use simpify curve because that will also eliminate other points I need that might be on a flat segment.
Attached follows a simple example definition + 3dm.
Thanks a lot!
I can see the problem but no solution. I'll keep thinking about this but it may require some custom VB/C# coding to consistently eliminate the unwanted points.
Wow, and I thought it was a simple problem...! So please let me know if you find a solution.
Thanks a lot for your time!
Wow again, thanks Dedackel!
It's the most complex offset I've ever seen, but it gets the job done.
Unfortunately when I use it on the file I'm working (much larger than that example I sent before) I still have unwanted points. And I can't apply the solution to several curves, they connect together strangely.
But I'll try to make the necessary modifications, as soon as I can completely understand your definition.
Thanks again for your time and effort!
mh, ok!? I am quiet sure there are possipilities to make my definition easier. But I can not spent more time on it right now, sorry. In the end it is not very complex. By the way. the Points you get with my version... at the end ther are to many. I guess there are duplicates or somthing like this.
Don't worry, you've already helped a lot!Yes, I saw the duplicate points too, and maybe that's why it doesn't work well on my file.
Thanks again and regards,
in my lunch time, I made this quick definition with out of the box components.
It makes polyLines out of every set of three sequential control points of the offset curve.
Then it filters for the Line-like segments and pulls their 2nd control point to the offset curve.
By Splitting the offset curve and rejoining the segments you get your control points along the line segment back.
Are the ControlPoints the same as the CurveCPs? I didn´t know that. I thought thy behave more like a t value on the new Curve!? Anyway good solution!
Amazing job, seems to work very well with curves with low curvature! I'll give it a try and let you know!
Thanks a lot!
But I guess the combo "discontinuity + polyline" is equivalent to a "simplify curve alone" isn't it? That way I'd lose the points on the flat segments I need aftwerwards, am I right?