As a person who does a lot of work with CNC cut plywood, when I first saw @Petras_Vestartas’ example for his
offset planar component, I was pretty excited.
Petras’ example takes almost any closed polyhedron with valence=3 vertices and can instantly transform it into mitered parts for each face. And while Petras warns that it won’t work with higher valence vertices, sometimes it does work for 4, 5, 6 or more edge intersections at a vertex.
I used the RhinoPolyhedra plugin to try to break Petras’ example, but the component is pretty damn robust. I love it! Here’s my definition for testing it:Ngons almost holy grail miter-izer.gh (449.0 KB)
The example above has some valence 4 vertices that work. When testing I did a lot of very close zoom-in inspections. In some cases, like with geodesic triangle spheres, the errors are tiny, in the .001-.005 unit range. When a high valence causes a failure it looks like this:
Could this be detected with a script?
That said…There are some pretty wild and unexpectedly cool situations in which the code works perfectly! Both of these are buildable using mitered sheet goods, all needed parts as individual breps.
There is also one minor bug: I found a few situations where, on non-convex faces, if an interior triangle mesh edge on a polyhedron face is close to colinear with an exterior edge of the face, the nGon conversion fails and produces an error in the final output. What’s interesting to me here is that different scale settings on the polyhedron produce different errors. Is this a tolerance issue?:
There is also another minor bugs sometimes with non-convex faces, also depends on the object scale:
One last thing: These NGons components are thoughtfully made so that if you explode the parts they output, the original polyhedron face is item zero, and the parallel offset face is list item one. This means no matter how many faces an output part has, you have easy access to them to assign planes for orienting.
I love this thing! Curious as to other people’s experiences and thoughts about what I wrote above, but mostly just wanted to post this in appreciation and so other people can play with it.