algorithmic modeling for Rhino
I am wondering if there is a method for creating meshes with Delaunay´s algorithm with RhinoCommon? I did not find it in the SDK help file.
Sorry, what are the constructors for this type, I did not find them in the help file.
no constructors, it exposes a bunch of static Solve_XXXX methods.
Thanks for your reply.
Just a quick question: how could I actually get the Delaunay mesh from a set of points then?
Grasshopper.Kernel.Geometry.Node2List nodes = new Grasshopper.Kernel.Geometry.Node2List();
for(int i = 0; i < points.Count; i++)
nodes.Append(new Grasshopper.Kernel.Geometry.Node2(points[i].X, points[i].Y));
List faces = Grasshopper.Kernel.Geometry.Delaunay.Solver.Solve_Faces(nodes, 0.0);
M = faces;
to get the faces but I don´t obtain the actual mesh faces and don´t know how to convert them.
I used that because I didn´t know what the List of faces referred to in the .Delaunay.Solver(node2List, double jitter, List<faces>) type.
With the code above what I get is a set of Delaunay.FaceEx.
If you want a Mesh, you should use Solve_Mesh() as it returns a Rhino.Geometry.Mesh instance.
Ok, David, I got it!