sliptonic wrote:Results from outline project using a compound of faces are still showing a bug though.
I was not clear in my previous post. When I said make a compound, I actually mean to make a compound of face and then extrude a solid. Because makeSection is supposed to only work with solid. I am surprised that you even get any result for face compound. And you have just stumbled upon an unexpected usage of Path.Area.
Here is what actually happened. Section won't work when there is no solid. So Area just do normal operation on all faces. When you set Coplanar=0, it will not check face plane, and simply convert face wires to 2D by ignore the Z value. That is actually some kind of projection! So, you don't need to call makeSections at all in this use case. The artifacts you see is due to those faces having some near coincident edges. If you enlarge the shape produced, you'll see the artifacts are actually small holes. So, by adding Outline=True, you can remove those holes.
After setting Outline=True
So in summary. Here is what you can do to get face outlines
Code: Select all
outline = Path.Area(Coplanar=0, Outline=True).add([face1, face2, face3]).getShape()
One more thing, I see lots of getShape(rebuild=True) and getShape(-1, rebuild=True). You normally don't need to do that. Simple getShape() will do in most cases. And only use getShape(index) to get individual section if you doing section with SectionCount parameter in Path.Area instead of calling makeSections, You almost never need to set rebuild=True, I added that for debugging purpose. You'll be wasting time to rebuild in most cases.