Hello!
I’m struggling with a grasshopper script to create a surface from contour lines imported from an Autocad file. The script works fine, when the area is rectangular or quadrangle (the green outline in the picture) but doesn’t work when it’s a polygon (the red outline).
I don’t know why it happens. Is there some other function that would work with the irregular outline (instead of Divide Surface)? Or should I somehow divide the irregular surface into quadrangles? I also don’t know how to do that…
another method, using bounding box. the resulting surface needs to be trimmed.
in the gh file, there’s a trim method, but it takes a while - so enable it to see. contours to surface_by_bbox.gh (26.0 KB)
I’m not at my computer but I believe there is a much simpler way to do this/speed this up with divide curve, patch, pull curve to patch, and surface trim then list item index 0 to return the single largest surface aka your topo.
By using divide curve initially you can have better control over your point sampling and I would also add a cull duplicates node in there to get rid of any points within a very close tolerance before you send to patch node.