For a while now I’ve been developing some remeshing tools in Grasshopper, but thought some of this work might be of interest to other Rhino users, so I’ve made a first attempt at turning it into a Rhino plugin.
This tool performs an iterative remeshing to generate a mesh of triangles which are approximately equal sized and equilateral, while preserving sharp features. For now it works only on Breps, and the only setting is for the target edge length. The original script contains several other options though, and if there is interest more of these could be exposed.
This tool makes uses of the Plankton mesh library, which is a collaboration between myself and Will Pearson (hi @will !)
I would emphasize that this is a very early test release, and probably likely to crash or fail. However, if you do want to try it out, any feedback is welcome.
MeshMachine.zip (33.6 KB)
You will need to unblock all 3 files
To run, type MMTriangles from the command line
Works like a charm, for a prototype… Is that something you plan to develop into regular Rhino command?
It would be great to see some sort of calculation progress (now Rhino just freezes for a bit) and also to be able to select many objects to process at once. Also - now it does not work with meshes - is that a possibility as well ??
I could see this very useful in many cases of our workflow.
Thanks for trying it out, good to hear.
Just testing for now, so no definite plans yet.
Yes - I think showing the progress is something that could be added.
Since the algorithm is iterative it can be nice to watch it doing its thing in realtime (as it does in Grasshopper, like this).
Right now MMTriangles just performs a fixed number of iterations - I set it at 30, which is usually enough to reach a good result, but if it is a very large mesh you might be waiting for a while.
Taking a mesh as input would certainly be possible, it might just require a bit more input from the user to specify the feature edges and vertices. With Breps this is easier because smooth curves for edges and corners are already identified. Also, if the starting mesh has really bad aspect ratios or lengths very far from the target, the remeshing struggles sometimes.
@DanielPiker this is great, it works very well. A very useful addition would be to adapt the face density based on local curvature: more resolution where it is needed.
This is probably my limited experience with grasshopper, but I can’t find the create plankton mesh component after installing the plank plankton gha. I did see it in the example .gh file though.
Also I have not figured out how to create meshes like the pictures you show above. Is there some form of documentation, other than skimming the grasshopper forum?
Sorry there’s not much documentation for this yet beyond what I’ve posted in the GH forum - I’ll try and upload some more examples and explanations soon.
@danielpiker1
i use the UV information for mapping. parametric UV layouts (rectangular) as derived from nurbs have advatages in special situations: example: pumpkin
I’m still not sure I follow. Do you mean mapping texture information to the triangular mesh, or actually having the meshing aligned with the UV directions?
This plugin is just for triangulated meshes, and is quite different from David E’s quad mesher.
no, i am not asking for alignement of the mesh edges. it is only about the 2d UV space used for texture mapping. here is an example, a single NURBs surface and the mesh generated with the rhino mesher:
when using the rhino mesher the mesh contains the UV information derived from the NURB.
this UV layout is parametric, meaning it is transformed into a 2d square, trims are cut out from the square, there are no real lenghts, but the relatve distances between the vertives are stretched in order to obtail the square. the following screenshot is from 3dsmax, it shows the mesh exported from rhino with a texture map (checker red/black) :
i used a checker map, to make things clearer but of course it works with any other picture:
when reducing the mesh, the remaining vertices obtain their position in 2d (=UV) space and the mapped picture keeps it position and scaling :
did you understand this explanation or are there any more questions?