Aligning Roads Along Topo Polysurface

Hi there!

I’ve been having the worst time today trying to do what I feel is a fairly simple idea (but seemingly difficult task) – please help! I’m preparing a file to be CNC’d and I’m trying to, essentially, BooleanDifference the roads from the topo surface. The site itself is a closed polysurface, and I’ve made the roads a continuous grid as one closed polysurface, but the issue is that the topo has some hills and I’m not able to align the roads properly. I’ve tried FlowAlongSurface, SetPt, random scripts in Grasshopper, a Python script that @Helvetosaur posted years ago (ProjectVolumesToSrfs.py), but nothing is working (though the Python script is closest). The Python script works in some areas, but keeps the volume planar, so it mostly doesn’t work.

I’m losing my mind – please help. It must be a closed polysurface in order to CNC. Attaching the current status. topo_wip.3dm (19.8 MB)

Thank you so much!

Ashley

Not sure if I’m following you. But I would curve dup the surface edges. Then project top view those curves onto the polysurface. Solid extrude them into the polysurface before boolean.

Well, you can’t solid extrude the result of the projection if it’s not planar…

@ashley_hastings One of the problems is that your top ‘topo’ surface is not a surface, but a multi-facet polysurface - which looks like it has been derived from a mesh via MeshToNurb… Won’t be easy to work with. I think I would try the following:

  • Replace that with a Drape over the existing polysurface
  • Make a copy of the Drape and use that to re-create your solid topo, keep the separate surface
  • DupBorder your road surface, project that onto the draped single surface
  • Use the projected curves to split the surface, discard all of the result but the road part
  • ExtrudeSrf both sides your projected road surface, boolean diffference that from the solid topo.
  • Done

Here is an example, don’t have time to explain all the details now, but can come back later…

Topo.zip (6.7 MB)

–Mitch

Forgot about that. I guess you could Duplicate and trim away the terrain polysurface. Then join and move the cut polysurfaces to the specific depth and boolean.

@ashley_hastings - below is a detailed file with the procedure… Note I had to cheat a tiny bit to get the BooleanDifference to succeed, I scaled the road curves by 1.0001 to make them just a tiny bit bigger than the box. Ideally a better way to do this would be to extend the original road curves a bit beyond the box to begin with in anticipation of the subtraction operation later.

TopoExample.zip (11.4 MB)

Also note - all of the procedure may not even be necessary if you are only interested in creating a CNC toolpath. There is a toolpath option in many programs that is called “Projection pocketing” or something similar, it projects a 2D pocketing toolpath onto some 3D geometry and allows you to determine the depth to which you want to cut. So you could simply run one of those with your original topo map and road curves without actually having to do anything else…

–Mitch

1 Like

@Helvetosaur – thank you so much! I took a break yesterday and am just getting back to this. I’ll have a look at what you came up with. After my cry for help, I stayed another two hours and was able to sort it (made a copy of the top surface, moved it down 1/16", and used it to BooleanSplit the road extrusions), but you’re right re: the surface and the low poly nature of it, I hate it. It was a MeshToNURB from a cadmapper mesh, so I’ll give your recommendations a go!

Thank you again – and ha! The scaling bit made me laugh because I had to do a similar thing with my late Friday night fix – scale changes of .0001 and such. Ridiculous.

It. worked. BEAUTIFULLY – thank you, @Helvetosaur! :smiley: