Split lines and delete the ones outside a surface


This is the last part of a bigger gh file that I’m practicing and learning with. I want to trim all the lines (mostly horizontal) at the intersection point with the surface and also delete all the lines that live outside of it (mostly vertical). I’ve been trying to do it with advice from other posts but I haven’t been able to make it work on mine. Any ideas on how can I do it?

STOOL_trim lines with surface.gh (124.6 KB)

Here’s one method.

240527a_STOOL_trim_lines_with_surface.gh (131.3 KB)


1 Like

Thanks a lot Kevin! I perfectly understood your logic and I was able to adapt it to my base file. I was overthinking and overcomplicating things with what I had in mind and wasn’t working.