Planarizing an NGON mesh

I’ve been trying to see if there a way to planarize an NGON mesh (mainly a dual mesh). I understand they are technically constructed of multiple triangles. Triangles are already planar so using kangaroo to planarize it has no effect. Any ideas? Is it even mathematically possible?

Note: I am looking to planarize without splitting the mesh.

Thank you for any help.

1 Like

Hi @nathanlundberg77 - Do you have an example of the kind of mesh you are looking to planarize?

It’s simpler when the shape is convex, and the more sphere-like it is the easier.
Here’s an example


planarize_ngons.gh (16.3 KB)

Note that with hexagonal meshes the panels generally need to change shape quite significantly to become planar.

In other cases it can sometimes be better to use the tangent-plane-intersection method

See also this old discussion

I find planarized hexagonal meshes (unless they’re essentially domes) tend to end up with unavoidably quite awkward looking and ugly shaped panels, just because of the inherent limitations caused by having 3 edges per vertex and planar faces. There are certain shapes such as hyperboloids where regular grids of bowtie shaped faces are possible, but for really freeform shapes with a mix of curvatures, making them into planar hexagons generally looks like a mess wherever the curvature changes.

1 Like

Hi @DanielPiker, thanks for the quick reply.

I just saw you added more to your response, I’ll look at that now.

Here is a cleaned up script of what I’m looking to do.
Planarize_NGON_01.gh (45.4 KB)

Edit: You’re first script is exactly what I needed and that explanation answered something I’ve been wondering about for a while. Thank you again!

Great.
Yes - your shape here planarizes quite nicely, as it is pretty close to a surface cut from a sphere.


planarize_ngons2.gh (20.4 KB)