Mesh Data Tree - Apply to all faces not just one

Attached is a gh file that takes a triangular mesh and works out face edge dimensions and angles.

I’m trying to add this to each face (Shown on face 0)…

I can do this for one face but then reach the limit of my data tree manipulation skills and can’t make it work for all the faces.

In the gh file, the group called TRIANGLE EDGES is the part that I am trying to make work for all faces. (42.5 KB) (44.6 KB)


Looks good from my phone! Will have a proper look later on my pc.

Looks like you’ve taken a different, more sensible, approach. Thanks!

I think it was a mistake to try and solve first for one face and then edit for all.

i love this solution its so simple and perfect !!!


I want to thicken the polylines into solids…

I want the profile of the struts to be like this…

where I can set the height and width at the top (200 and 50).

I can’t figure out a nice way to control the offset so the profile retains the two 90 degree conditions. (66.4 KB)

hav a look (66.8 KB)

Thanks I will chexk this out later today…

Not bad, but not quite what I’m after.
Your struts don’t mitre at the nodes - they overlap…

I’m aiming for this…

Note that the strut cross section( 200x50) is NOT a rectangle! It has two 90degree angles only.

If each face triangle had been made from 200x50mm cross section and the face-to-face angle put on each side of the triangle… the inside faces of the triangle edge should be right angles and the outside corresponds to the face-to-face angle.

Offset the whole mesh, loft each triangle to the relative offseted triangle.
Do solid intersection with each beam to their relative triangle.

Or like this: (60.6 KB)
This is not using any solid boolean operation or surface/brep intersection, so the result is a mesh calculated almost realtime.

(If you need breps just replace the last big Merge with a “Twisted Box” and cast it to a brep parameter… but it’s way slower…
Note that “Twisted box” is actually really fast, it’s the brep parameter that is slow.
You could leave the mesh preview as i did, and bake/use the twisted box when needed)


Looks perfect. I will check it out properly later.

A mesh is fine as an output.

I might try and remove the Loft component too as that can slow it all down.

thanks for sharing very nicely done !!!

For some reason the Plane Line Intersect component doesn’t work for me. I’m on R5 so had to add the multiplication back and got an error for the FaceB component but swapped these for R5 components.

The PLX component gives really weird results…

EDIT: its not the PLX component, its the order of the FaceB data is different so all the mesh points get out of synch.

It’s given me a method to try and recreate though, thanks! (54.2 KB)


That’s great work again, thanks @maje90.

Something is puzzling me though… I was expecting the angle between faces to be equal but it is not…

Is this something to do with the Mesh Offset?

Why do I care?.. Imagine I were to make this structure from 200mm x 50mm timber… I would make each triangle as per the mitre angles and then add an angle to each side of the triangle corresponding to half the face-to-face angle. That’s why I’d expect 90degrees on the inside of the triangles.

I started doing this on a small scale by just calculating the angles needed to cut the timber for 20x20mm timber and it seemed to work but I want to model it as it would be made.

That’s expected.
The mesh offset is not a real offset but it’s done by moving the vertexes of the mesh, the result will be truly correct only if the mesh is conical.
When 4 faces share a common vertex, the resulting offset usually would result in a complex shape, not again a simple vertex.
To understand what i’m saying try to convert it into a polysurface and make the offset on rhino.

You’ll get symmetric beams only with structures like regular solids and such…

1 Like

So if I did actually make this by building the triangles and putting half the face-to-face angle on the edges then it would fit together but I would have a mismatch of the struts on the underside of the mesh where they meet at the nodes?

And I suppose I should check if the struts end up being straight or twisted too!