I have a given planar surface and want to mesh it with a homogeneous triangular mesh. I’ve tried several methods to achieve an aesthetically pleasing result, and I’ve found that constructing a quad mesh with grid lines aligned parallel to the two edges on the left side gives me the best outcome. To achieve this, I manually created the lines and trimmed them using the boundary line.
The only issue I haven’t been able to solve is avoiding artifacts and n-gons at the edges of the mesh. I’ve tried optimizing it using Galapagos with different objectives, but I haven’t been able to overcome a certain threshold - the result is still far from optimal.
I’m also unsure which approach is better:
Creating a pure triangular mesh directly, or
Generating a quad/triangle mesh and triangulate the quads afterwards
Can anyone give me a hint or point me in the right direction to solve this problem?
I have to ask - is this a one-off or a generative design with multiple shapes?
Because it probably takes as long to eyeball it as it does to find a robust grasshopper solution. Reason being that your constraints (small, big triangles) are rather fuzzy. If I was doing this for a single shape, I’d programmatically set up the principle grid angles and play around with the spacing until the RH side looks ok, then clean up the leftovers manually.
The one-off would be the very last solution if I can’t find a generative design. I want to reuse the mesh for designing a gridshell and it should be optimized after static constraints as much as possible.
Your goals of avoiding tiny triangles and ngons are essentially constraints on the grid topology.
The key is to start with a polygon on a regular triangular grid, with its vertices on grid vertices, and edges following either the grid directions or their bisectors:
Is there a way to get this line also parallel to the outer line? Or is it geometrically impossible? It would be also okay if the curve changes a little bit. I’ve tried so hard to find a way, but I’m stuck.
I want to relax the mesh afterward with kangaroo in the third dimension to get a shell, cloud there be a way to make it more homogeneous? Maybe fix the third dimension and then remesh but whith a tolerance of deviations from the shell shape
It seems both here and in your other thread the options presented so far are more workarounds than bulletproof solutions. Same for mine. Check if it helps: shape_gridfit.gh (55.5 KB)
*Edit:
Just realized I left some redundant components at the top of the script (Face Boundaries, Simple Mesh, and Combine & Clean) after the Mesh Surface + Triangulate Mesh combo. Didn’t pay attention, some were there already - feel free to discard.
In that post you seemed to care less about existing ‘artifacts’ or other discrepancies.
Anyway, I won’t say I’ve understood but it seems based on the title of this thread that your ‘aesthetic’ mesh needs to be made of only triangular faces and have an edge construction that is nearly parallel to the boundary:
Second, run kangaroo and afterwards still pull the naked vertices to the boundary because even with your 100000 strength value kangaroo won’t put them on the curve.
Another option is to try QuadRemesh instead of MeshUV at the beginning then triangulate that, but it might do some weird stuff if you use a target edge length. However maybe it can help if the mesh is built with symmetry.