Daniel. If possible i would strongly vote for this feature of meshing to isolated points. I have to do this all the time when generating FEA meshes. If we can just add these points as a feature input and re-mesh to them it would be superb.
So, in your work around it looks like you re mesh the starting Geometry mesh based on user defined isolated points.(I didn’t know the mesh nearest point method!) Then create fictitious lines that have an end point on the new mesh/isolated points and then use these as features.
some question about the code syntax which is new to my c# basic understanding
int fi = m1.Faces[f].IsQuad ? 4 : 3;
What does the ? operator do here? Short cut flag for if true/false?
2) for(int j = 0;j < fi;j++)
m1.Faces.AddFace(m1.Faces[f][j], m1.Faces[f][(j + 1) % fi], v);
What is the % operator doing here for m1.Faces[f][(j + 1) % fi]
i got it to work by doing as you suggested, splitting the surface with the segments of the poly line, rejoining the surface, sending surface as input geometry and sending segments as features. Its meshing along polylines now, thanks.
Yes, the ?a:b is a convenient way of doing inline conditionals:
and I was using (j + 1) % fi
to make sure the indexing wraps when taking the next point around the boundary (to get the edge between vert 2 and 0 if it is a triangle, or between 3 and 0 when it is a quad).
I’ll make sure isolated point inputs work properly in the next release
(it was working before, and the code is all still in there, I just changed the component at the last moment from having separate inputs for feature points and feature curves, to having one combined input, and forgot to properly update the data types and casting)
I’ll also update the component to allow the setting of isolated feature points which do not already exist in the input Brep or Mesh.
Thank you! I’m really very happy that you’ve circled back to remeshing, this has been a sore point for me in Rhino for literally decades, and since Meshmachine we’ve known you have the answer. This seems quite robust, I’m already using it in production. The mesh quality is top-notch, and speed is not bad even for quite big meshes.
This kind of thing is my day job https://crystalproteins.com/proof/1783/
and isotropic remeshing is the easiest way to get those pretty point distributions, so this is daily workflow for me. Now I can get rid of some annoying detours into Zbrush and Meshmixer!
Yes, it will currently fail if the input has non-manifold edges or is non-orientable.
I’ll see if I can do anything to get it to heal some of these cases.
For now one option with bad meshes is to take a good mesh and wrap it onto the bad one.
The sphere projection technique I was trying here is a bit faster than starting from just the bounding box, though still takes ages to pull all the way in to the concave regions at this density. There are some internal variables for how far it allows a vertex to be projected, and I wonder if exposing these might allow it to reach a tight wrap in reasonable time.
Another option is to start from an isosurface. Here’s a go using Dendro to generate a starting mesh then TriRemesh to improve the triangle quality. It takes a while but gets there in the end. triremesh_dendro.gh (10.8 KB)
(though whenever it is possible to fix non-manifold edges before remeshing, I think that will be fastest)
Mm interesting roundup. Thank you. Yes, I have a lot of these protein surfaces and they can have very deep pockets. No lie though, Dendro solves a lot of problems!