Mesh face creation with Dynamo

Hey all, next project is to import some point data from a Trimble from a site survey. I have some very difficult Topo to model, and I have points for most of the vertex locations, so after reading on surfaces, a mesh is the way to go. (I don’t have depth, and it’s not a point cloud file, just a staked location file.)

Using Dynamo, I have points imported, and created at each survey point.

Trying to create a Mesh.ByPointFaceIndices, the example in the help file is difficult to understand since it’s just a code block, I’m not sure if I have the information I need or not already from the “survey points”.

I’m obviously missing my indices, but what is it looking for? The help file says the index is a list of groups to define points, so do I need to identify which “points” go together to form the face? Without a LOT of longhand research, this would be extremely difficult to identify.

In a follow up post, I’ll post photographs of the site and my Revit model to date to help visualize what I’m up against.

So I’m not getting an IndexGroup here, there’s something I just don’t understand with these nodes. Do I need to label EVERY point, and in the IndexGroup call out every single point again to give it an identifier? (Seems what A, B, C, D, E is doing in the example.) The Help example is in the bottom right corner of my screenshot for reference.

Switched to using a NURBS surface, probably not what I need but it’s working on a set of isolated points. (I edited the .CSV file to only contain 4 adjacent points.) If I feed in my actual list it fails. I understand it needs to know what 4 points to draw a box around for the surface shape, but how do you script them to a list, as essentially I want a vertex drawn between all adjacent points. There’s a few hundred points, and so far each example I’ve seen have been typed out longhand for the index when using a mesh. Since a NURB surface only needed the parameters of the points, it completed my shape.

A with lace shortest? Features I haven’t used yet, and not really sure what the solution is at this point to proceed.

Because I’m OCD, more progress. It’s gotta be the order of the points I’m thinking, but really not sure.

So a mesh is an ordered set of points- ordered into triangles - you don’t know the order of your points or if they form any triangles so you’ll need to investigate algorithms which take unordered point clouds and convert them to meshes or sets of triangles.

The index groups define triangles or quads.

Use the “Topography.ByPoints” node first. That way you’ll be able to use Revit’s built-in triangulation methods to split the points into triangles using a least squares algorithm. You can then extract back the resulting mesh with the “Topography.Mesh” node to get a dynamo mesh.

Finally, if you need to convert that mesh to something that other softwares can use, you can get the toolkit mesh from the package manager and spring nodes. You can then use “Springs.Mesh.ToToolkitMesh” to convert the mesh to something that can be exported out of Dynamo.

1 Like