Tutorials · ALAR 4010 / 8010 · Fall 2026
Rhino Topography Model from Contour Lines
A step-by-step guide for turning contour lines into a three-dimensional terrain surface in Rhino, using native Rhino tools or a Grasshopper definition. This continues from the QGIS walkthrough, which ends by exporting contours to DXF or DWG.
- Software: Rhino 8 (Rhino 7 works; Grasshopper ships with both).
- Input: contour lines, ideally 3D polylines at their true elevation, from the QGIS export (DXF, or the DWG prepared from it).
- Two routes: native Rhino (Patch, Loft, MeshPatch) or Grasshopper (Delaunay Mesh).
- Rule of thumb: use a mesh for rendering and GIS work; use a NURBS surface only when you need smooth, sectionable geometry.
- Units: the Venice lagoon is modeled in meters (EPSG:3003). Set Rhino's model units to meters before importing.
The most common terrain failure is contours sitting at the wrong elevation. Before you build anything, confirm whether your lines already have a Z height.
- Import the DXF or DWG: File → Import, choose the `.dxf` or `.dwg`.
- Select a contour and check Properties (or run the What command). Read the point coordinates.
- If the Z values are real elevations, your lines are already 3D and you can skip to section 2.
- If every Z is 0, the lines are flat and you must assign elevations first (below).
- If contours arrived as many short segments, select all curves (SelCrv) and run Join so each contour is a single closed polyline. Closed polylines build far more cleanly.
- Move by a known amount: select the contour and run Move, then type `0,0,5.5` to raise it to 5.5 m. Or drag the blue gumball arrow and type the value.
- Set to an absolute height: run SetPt, select the contour, choose the Set Z option, and type the elevation. SetPt moves every point to that one height while leaving X and Y alone.
- Many contours at once: read the elevation from a layer name or label. Doing this by hand is slow, which is exactly when the Grasshopper route in section 4 pays off.
Three commands turn contours into a surface. Each surface type has different characteristics.
The most common starting point. Produces a smooth NURBS surface.
- Run Patch.
- Select all contours and press Enter.
- Set the options:
- Sample point spacing: start around one twentieth of the site width. Smaller catches more detail.
- Surface U/V spans: more spans means a smoother but heavier surface.
- Stiffness: raise it to keep the surface close to the contours and stop it ballooning between them.
- Press Enter and inspect the result against the contours in a side viewport.
Builds a NURBS surface that passes exactly through the lines.
- Run Loft.
- Select the contours in elevation order, bottom to top. Do not skip around.
- Accept the default Normal style and confirm.
- If the surface twists, simplify the contours with Rebuild first, or switch to Patch or MeshPatch.
Creates a triangulated mesh. This is the best choice for rendering, GIS, and most landscape work.
- Run MeshPatch.
- Select all contours and press Enter.
- Raise the density if close contours need more resolution. The result is already a mesh.
Before moving on, make sure the model is honest.
- Switch to Shaded mode and orbit. Look for spikes, holes, and flat spots between contours.
- Cut a section with Intersect or a clipping plane and compare it to the contours.
- If a Patch surface bulges between contours, raise its stiffness or rebuild with MeshPatch.
- Repair small holes or spikes by patching that region, or by trimming.
Grasshopper is a good option when you have many contours, when elevations live in layer names, or when you want a clean triangulated mesh with no hand tuning.
- Type Grasshopper in Rhino to open it.
- Add a Curve parameter (Params → Geometry → Curve). Right-click it, choose Set Multiple Curves, and select the contours in Rhino.
- Extract points from the contours. Two options:
- Discontinuity (Curve → Analysis): returns the corner vertices of each polyline. Fast and exactly on the data.
- Divide Curve (Curve → Division): samples points along each line when you need more resolution than the vertices give.
- Triangulate with Delaunay Mesh (Mesh → Triangulation). Connect the points.
- Optionally clean the result with Weld (Mesh → Util) at a small angle, and check the normals with Rhino's Flip or UnifyMeshNormals.
- Bake the final mesh (right-click the component, choose Bake) to bring it into Rhino as a real object.
This does not apply to the current base dxf or dwg but may be useful for other files. If each contour's elevation is stored in its layer name, a layer-name component (from the Elefront or Human plugin) lets you read it, parse the number, and move each contour to that Z in a single definition. One setup replaces hours of manual SetPt.
- Mesh is the landscape default: it renders fast, exports cleanly to GIS or other software and render engines, and does not distort between contours.
- NURBS is for smooth, sectionable, machine-able geometry and clean drawings.
- Convert between them with MeshToNURB (mesh to polysurface) or Mesh (NURBS surface to mesh at any resolution).
- Contours at Z = 0: assign elevations first, or the surface comes out flat.
- Patch balloons between contours: raise stiffness, or use MeshPatch.
- Loft twists: select contours in order, or simplify them with Rebuild.
- Holes or spikes: patch the region, or trim.
- Mesh normals inside-out: Flip or UnifyMeshNormals.
- Model too heavy: rebuild with fewer spans, or reduce the mesh with ReduceMesh.