Select Outer Corners Using Grasshopper

Hey there,

I have a closed curve and want to select outer corner points on this curve. The points are shown on an attached picture and curve is in attached grasshopper definition. Is there a way to do that?

curve.gh (3.5 KB)

Thank you in advance.

1 Like

Thank you for your response. But I wanted to select only the outer ones as shown on the attached picture. Is there a way to do that?

Thank you for you response. Circles were only for demonstration purposes only to indicate the outer points that i want to select. Discontinuity component selects all the points, even the inner ones. And I want only the outer ones to be selected. Is this possible?

get the angle to cull the inner ones

1 Like

Something like that

you take the tangent at end of segment then reversed tangent at start for next segment then measure the angle and decide the threshold (180 or PI here)

3 Likes

thank you so much! It did work!

Are you sure of this ? Angle is the minimum < PI

curve discontinuity.gh (17.9 KB)

Thanks for the detailed assistance, my recommendations were just to get them pointed in the right direction. That would have almost worked except for the one outlier.

Just to be sure, by “outside corner” we just mean one with an internal angle of <180° right? Nothing to do with proximity to the convex hull? So this would be an “outside corner” according to the definition?

I am not sure of the Grasshopper result

it might be indeed considered as “outside corner” in this case. If not, one can use conbex hull to pick out outer bounderies, right?

If the curve is planar, you can extrude it and with the convex edges component find the corners on the convex edges which have the length you extruded.

2 Likes

Exceeeept, point #144 in the last image in the post above would still miss out …

1 Like

Yes with a drawing I now understand Grasshopper calculation !!! Left drawing was indeed my calculation

The difference lies in how Angle and Evaluate Curve measure angles. With Angle (the figure on the left) the angle is measured from vector A to vector B, clockwise in the assumed plane, while Evaluate Curve measure the interior angle between the incoming and outgoing vectors. This also means that the angle measurement you get from Evaluate Curve cannot be used to ascertain the left- or righthandedness of the corner.

4 Likes

My personal interpretation.

curvee.gh (14.7 KB)

3 Likes