I am importing contours into Sketchup and creating a surface using the sandbox tool. when it creates the contours it goes beyond the outside shape of the base contour and connects any internal indentations, hopefully the attached picture explains this a bit better.
I need to remove all of these lines, so that the shape of the surface, fits with the outside shape of the base contour. I can do this manually, but on some models I have thousands of these instances, so it takes hours. Does anybody have a suggestion to speed this up?
I am wondering whether I could bulk select any lines, outside the base contour, but from looking I can’t find anything like this?
My first inclination would be to use CleanUp3 to merge coplanar faces and repair split edges. I’d also be inclined to run Eneroth Auto Weld to weld all possible edges. Thenit should be easy to erase those edges and faces outside of your terrain.
FWIW, if you need the terrain to be a solid oject, it might make sense to keep those flat areas around the terrain. It would make creating a skirt easier.
How about drawing a surrounding border any shape, but much lower than any contour. Make sure the bounding edges have vertices (divide) such that the indents autofill to these lower points. Then erase all of these lower faces are easily selectable from side view.
Thanks for that suggestion, I’ve followed the same steps but I seem to be losing detail at the last stage when I remove the outer edges that remain. since the remaining surface does not fully cover the contours.
Unfortunately Dan, even with another contour below the level I want to outline, it creates links on every contour level. So whilst your suggestion cleans it up a bit, it doesn’t clean up the fiddly bits which are left as per my original screenshot with the blue arrows, thanks though!
On that model it seems to be 1inch, although that can’t be the actual interval when converted to real life scale.
I have found that if I explode the two groups, so they merge, then it has this effect so allows me to remove only the portion between the original contour groups. There is maybe a better way of doing this than having to explode the two groups, but it seems to work?
You can see between the two screenshots, how the area I have selected on the bottom screenshot is bound by the contours, rather than overlapping into them and removing the outline I wish to keep.
When you run clean up3 and want to delete una wanted lines, all the lines that aren’t forming faces and are coplanar to a face without affecting its shape, will be deleted, you can group the contour lines and put them on a hidden tag, copy them run clean up3 and paste them again in place, or get into the mesh and on the settings of clean up select to run the operations just inside the group or with the selected geometry.
Personally I prefer to use TopoShaper from Fredo6 to create terrains, it generates more geometry but depending on how you set it up you can have a lot more detailed terrains and without the geometry that the sandbox tool sometimes creates. If the terrain you’re workin with isn’t too big you could even get a mesh with a lot of detail without having performance problems.
The best way I’ve found is to use the Simplify Contours extension inside SU It makes many mini line segments that make up a single contour into a polyline. There by cleaning and minimizing the file size. The external extra topo seems to be inevitable. Also, Erase as much bs from the cad file first
I erase everything thing but the actual topo lines and run from Contours again if necessary.
Are you running sandbox on separate islands of contours and they are being connected? If so just convert each island separately.
Otherwise my process is:
Create terrain which makes a group
Copy bottom contour into group
The copied contour breaks the single terrain surface into inside & outside surfaces
Select all > deselect inside surface & boundary by CTRL+SHIFT+Click twice
Just the outside surfaces and borders are selected
The problem I have had with TopoShaper is the time it is taking, for the same contours as I showed in my second post, it took numerous minutes to generate a surface. Initially it wanted to do a 50x27 grid, I changed that to 200x107, otherwise the level of detail it was generating was definitely poorer than just the Sandbox tool. At the 200 grid detail, I would say its better, I particularly like that the top are curved rather than flat, but it took probably 50 times longer to generate.
Is this experience to be expected, for such a small set of contours?
The contours above have 3318 edges, the actual file I am working with has 397,215 edges. Hence the desire to find a quicker way to clean up the edges, as it takes hours doing it manually.
@dan20047 Thanks, that process works great. One question, what is the purpose of points 6 and 7? After following up to point 5, I just pressed the delete key and I think it achieved what I wanted, how do Selection Toys and Eneroth Extended Deletion extensions differ what just using the delete key?
Tiposhaoer takes a bit more of time but not 50 times more, right now I’m working on a project and had to model a terrain from contour lines, the terrain is 20000 m2, the mesh was set to 150x75 and it took just a few seconds to generate the mesh, maybe 3 more seconds than with sandbox, but the mesh is a lot better. What are the specs of your machine? I created the terrain on my M1 Max MacBook but I also work on a desktop pc, and just out of curiosity generated the exact same terrain on it and it was almost the same time.
I am working on a desktop PC, but its pretty old. Although still surprising that it takes me seconds with the Sandbox tool, but minutes with TopoShaper, on this small test. Using the large contour sets I have, it does take a couple of hours with Sandbox.
Intel(R) Core™ i5-4670K CPU @ 3.40GHz 3.40 GHz
8gb RAM
I’m gonna make a test with my old 2013 MacBook with a 4th gen i7 and integrated graphics, that was my machine for many years and I used toposhaper there as well but it didn’t take hours to generate a mesh with toposhaper or sandbox, not even minutes. There must be something wrong with your Pc, are the drivers up to date?
In my test even when deselecting the inside surface, some edges connected to that surface are selected, and the delete key erases faces that should be kept. As a general working method I’ve had that problem too many times and developed a habit with keyboard shortcuts using those extensions to select only faces and then delete those faces, and Eneroth’s extention makes sure the bounding edges hidden or not are also erased. (For me CTRL+SHIFT+F to select only faces & CTRL+SHIFT+D for Extended Deletion.)
I am having some issues using this method on a larger scale, with contours that are not closed. Compared with your example, it would be half of that set, cut down the middle. I am following the same process of copying the base contour, but its not breaking up the surface as I expected. I’ve tried a few things, but not making progress, any ideas?
I’ve just done this, so its confusing me even more now.
As you can see from this screenshot, the surface is spreading over into the waste bits that I wish to remove, even though I’ve copied the base contour. So I went into that group, copied the outside line and the base contour then pasted it outside the group. As you can see, it makes a shape with a face, so I’m unsure why its not acting the same when inside the group?