Delete none-bounding edges
-
Hi,
I've got lots of detailed contours but on the flat edges they have intersected with the terrain mesh.
How can I remove the non-bounding edges?
Currently I am using "make faces" and then "cleanup" to merge co-planer faces and then removing the faces after so its just the bounding edges left.
But there are problems with this, first of all make faces isn't making faces when there is are stray edges bleeding into where the face should be. Also issues with performance, it takes AGES to make the faces first for cleanup to work from.
Is there a way to cleanup to remove all the edges except bounding edges? Not bothered about preserving any islands as there are none of use.
-
Bounding edges are associated with only one face so it you select everything, open the Ruby Console window and paste and execute this, s=Sketchup.active_model.selection.grep(Sketchup::Edge);s.reject!{|e|e.faces.length==1};s.each{|e|e.erase!}
All interior edges should be deleted.
-
Thanks but it did not work - see below.
@unknownuser said:
s=Sketchup.active_model.selection.grep(Sketchup::Edge);s.reject!{|e|e.faces.length==1};s.each{|e|e.erase!}
Error: #<TypeError: reference to deleted DrawingElement>
<main>:inerase!' <main>:in
block in <main>'
<main>:ineach' <main>:in
<main>'
SketchUp:1:in `eval'I also could not undo as it is treating each delete as a single undo so I would have to press it 100 times if it deleted 100 lines.
edit: I have tried it on a selection with faces and it worked - but this is exactly what the cleanup extension does.
Is there any way to do this without generating faces as this is what is taking the time to process with so many lines?
-
Can you share an example file to play with?
-
@lersince1991 said:
Thanks but it did not work - see below.
@unknownuser said:
Is there any way to do this without generating faces as this is what is taking the time to process with so many lines?
Without the faces, there is no way to differentiate between interior and bounding edges.
-
Why don't you make the big face (just join 2 vertices of the big contour, assuming it is flat) and then cleanup the coplanar edges with Thomthom's Cleanup or FredoTools::EdgeInspector?
Fredo
-
I need the outer bounding edges rather than the inner.
-
@lersince1991 said:
I need the outer bounding edges rather than the inner.
I think everyone understands you want the bounding edges. Are they on the same plane? If so, retracing any edge will create the face which will then allow for the identification of the edges that form the boundary.
If you can share a sample model, it will help us help you.
Advertisement