Flatten polygonal surfaces in Rhino?

Hey guys, modeled this way before in Cinema and reconstructed in Rhino later. Now preparing for production and I have to reshape, declutter and remove some polygonal surfaces. Since even >4-point-polygon-surfaces (ngons) should be planar I’m looking for an easy way to simply flatten 2 or more adjacent surfaces with one click to have all points planar. There was a script in Cinema called “Flatten” which would align all polys to the construction plane of the 1st selected poly. Is there something similar in Rhino? Since working with polygons is limited and 3point surfaces are trimmed 4point-surfaces so you can’t simply drag the endpoints.

Thanks a lot for your help!

If these are meshes, you could use _Merge2MeshFaces to remove an edge between two faces.

Thanks @fraguada for the immediate response! Will test this. What would help me as well is i.e. if you can tell me how to snap a CPlane to a face/poly to use the set point command. Rhino doesn’t accept polygons for some strange reason.

@fraguada Luis! tried this, but this would only delete the edge which results in a 4 sides poly which is not planar but a bend surface.
I need planar surfaces, this is why I’m looking for a same script like in Cinema which would kind of rotate or project the adjacent faces onto the plane of the 1st selected poly.

Important since I want to cut the polygons and triangles out of planar material (steal or MDF)

THanks for your further ideas!!!

I might run MeshToNurb on the mesh and then UnrollSrf the resulting polysurface to get everything flat for cutting…


1 Like

Hey Mitch, this might not be this precise for production resulting in open edges in the final product. Do you know a way how to include faces/polygons for setting construction planes (which currently is not working)? This will help!


The resulting polysurface from MeshToNurb shouldn’t be any less precise than the original mesh…

If Hannes only wants to copy the current triangles onto a single plan for cutting then Mitch’s solution works.

However if Hannes wants to consolidate almost coplanar triangles into planar surfaces then control points need to be moved.

@hannesgrebin What do you mean by “polys”? CPlane with the Object option works for me in setting a cplane to a triangular face of a polysurface. If you object is a mesh not a polysurface then run MeshToNurb to transform it into a polysurface.

Edit of Edit: Use “Trim triangular faces = No” in MeshToNurb to obtain triangles rather than trimmed quads.

CPlane wit the 3Point option may also be useful in some instances where a the desired plane does not coincide with a single triangle.

Also as I’m sure you know you’ll need to explode the polysurface into individual surfaces before turning on the control points.

Thanks all! I think the best way would be to work in converted polygons but is there a way to match construction plane with a single mesh? Would be of massive help!

Thanks a lot!

By a “single mesh” do you mean a single face of a mesh? If so try CPlane with 3Point option, Vertex OSnap on, selecting three vertices to define the CPlane. Keep in mind that a quad (4 vertices) mesh face might not be planar. If so it is not possible to exactly align the CPlane to a non-planar surface.

Thanks David! Damn quick. But just clicking the face doesn’t work? No script for that to select a face and which would calculate a plane (like Plane average through points)? Would be handy :slight_smile:

hi @hannesgrebin,

here are two scripted tools that should be helpful:

  1. cplane to mesh face aligner - sets CPlane to selected mesh face (you keep picking until you are happy with the selection). This script would help if you want to tweak your mesh manually - in that case, turn the vertex grips ON, then use Move tommand and turn Project (Osnaps) when asked for grip desination - it would snap to your cplane.
    CplaneFromMeshFacePick.rvb (948 Bytes)

  2. mesh faces flattener - should work similar to the one you mentioned from C4D - pick a mesh face as the source for your plan (or skip to average the plane for all faces you want to flatten), then pick the faces you want flat.
    Please note that if your mesh is unwelded, the flattened faces will disconnect. For welded ones it will stay together.
    PlanarizeMeshFaces.rvb (2.3 KB)

Here is a quick clip of how that should work

P.S. SetPt seems to work OK with mesh grips, so if you use #1 with CPlane and Z set to 0 it should make the job easier.



1 Like

The CPlane from mesh face has been added to Rhino 6 WIP, fyi.

1 Like

If you’re willing to jump into Grasshopper you might to check out the Ivy plugin.

Thanks so much Jarek! This is what I need!!!

@AndersDeleuran Thanks for putting this one out. Will finally get my hands on Grasshopper.

@Jarek your PlanarizeMeshFaces.rvb doesn’t work anymore, can you tell what to do? Thank you!

hi Hannes,

From the message it looks like it’s not code error but rather how the script is loaded.
How are you running it?
Have you tried drag-and-drop into Rhino vport in order to run it?

EDIT: Just tested it, all works fine over here. Can you try downloading the file again and running it the way mentioned?