MeshPatch Command

MeshPatch command when creating a Mesh from contour lines creates flat tops in valleys and also on ridges. Is there anyway to avoid this inconsistency when using MeshPatch? Is there a better way to create a mesh from contour lines? It also does it when using Delaunay Mesh in Grasshopper. Does Delaunay Mesh in GH use the same technique as MeshPatch in Rhino?

Mesh (3.7 KB)
Mesh Valleys.3dm (2.5 MB)

Yes, they use the same basic algorithm, and yes, this effet is pretty common. In general it is best to avoid making terrain meshes from contour curves if possible, as this kind of stuff is bound to happen. Contour lines are already an interpretation/interpolation of DEM height points, so one step removed from the original measures. Remaking a mesh from those is then two steps removed.

All data in between the contour curves is simply linearly interpolated (and not always in the best fashion) and thus does not necessarily accurately reflect what the terrain is really doing in that area.
This is especially true in the flatter areas where the spacing between contour curves is large.

The best thing to do is try and find a DEM points file and create your terrain mesh from that. At least then you know that the terrain mesh is accurate at each data point, and as the points are regularly spaced even in the flatter areas, you have more data points to work with and the effect you see above should not happen.

Unfortunately, these contours are all that I can go by and the person who gave me this isn’t willing to give me anything else. Is there a better command that can create the mesh with a different algorithm that would come out better on the ridges and in the valleys?

A shot in the dark, but does a QuadRemesh of the mesh do anything you like - to say 5000+ quads?


I lose a lot of accuracy if I use QuadRemesh @ 5000+ quads. Even tried it at 20k. The mesh was created from the contours and it did great except for the ridges and valleys.

Not that I know of. The only way I have to fix this stuff is to give the mesh patch additional points to go through in order to force a better subdivision. This is completely manual.

One way -

  • Draw polylines in between the contours in the valley areas (snapping to contour lines)
  • Explode the polylines and Rebuild with say 10 points (so each segment has ~10 points)
  • Select the contour lines and the drawn polylines, ExtractPt to get points
  • MeshPatch the points

This is just a small sample area I tried on your file:

Another way:

  • Use TweenCurves in between neighboring contour lines with a large amount of sample points to get decent intermediate data points
  • Include those in your MeshPatch

TweenCurves helped but it did create the same problem, just at a smaller scale. It certainly is better than it was.

I like the idea of the poly line. Great suggestion!