Hi Anders, Thanks for the Response but what iam expecting is a node or a python code which works generic for any number of lines or polygons the shown image is just as example
If you have a surface containing all these polygons you could use the Geometry.DistanceTo node to determine the polygons distance to the perimetercurve. If the value isn’t 0 you know you have one of the inner polygons.
I’ve worked out a solution for your problem. I found it intersting to solve and therefore had been busy with it for a while.
Input:
lines that cross eact other
the max number of vertices, this number should be as small as possible to reduce computational cost, because it uses a recursive function.
By now the script doens’t work when three lines cross each other at one point. Maybe I will fix this later.
In other cases it should work as shown below.
Notice, draw your lines on the same leve with elevation 0. The elevation can be adjusted when needed.