Closest Points Issue

Hey Guys, I would like to build these triangular segments on the mesh with the curve closest points component. The Problem is that in some cases the ‘point to search from’ picks closest points which are not right, because they are nearer then the ones I actually need (see picture below). I tried to fix this by selecting the 6 curves which intersect in that points, but I don’t really manage to do that. Any ideas how I can solve my problem?

He is selecting that point:

Instead of this one:

Closest Points Issue.gh (51.3 KB)

I got most of the way through solving it. I used Brep/Curve Intersection to find what curve went through what point. Then Convex Hull was used to create a shape to sort the generated points around. Then I got tired and did some dodgy stuff to create the shapes you need. Most are okay, some need work. I’ll have another view in the morning. Hope this kind of helped!

Closest Points Issue_DZ.gh (89.1 KB)

This helps me a lot, thank you! At the moment I don’t understand why the inner and the outer points are sorted different in some cases, althought they are sorted along the same curve… But maybe I will figure it out

Second Problem is that I need the segments to be in the same direction. At the moment they are oriented in different directions