Creating a 3d model of a terrain

This means your installation of MapWinGIS was successful.

The “_APIkey” is the last step.
You basically have to create a free account at, and the APIkey will be generated automatically.

  1. Got to: OpenTopography Data

  2. Make a new account:

  3. Copy the APIkey and plug it to “_APIkey” input of the “Terrain Generator” component:

That’s all.
Don’t share you APIkey here publically (by attaching a .gh file for example).

I was also having problems with the raster image preview at first, but the the topography itself generated fine with your Glen Etive file (it did take a little while to connect to the source server).
As mentioned above, make sure the boundary curve you have is big enough (it’s in real units, so if your rhino unit space is cm, you have to make it much larger).

The preview itself is sensitive to the display mode of Rhino, when in Rendered Mode, you have to be sure that the Lighting scheme is set to ‘Ambient Occlusion’ to see it in Grasshopper preview.

In order to use the image texture outside of Grasshopper, you can use other Human components:

  • Create/Modify Materials,
  • Create Attributes, and
  • Bake with Attributes
    as shown here.

Select the image source you want from the ESRI Raster Value List (here, it is Street Map) and then double-click the last boolean toggle to True to bake it into your Rhino model.

Glen Etive (22.0 KB)

1 Like

Hi @wim ,
I’m seeing an EPSG:4326 component message under the RESTRaster component @Hobnob is using, which means he should have v0.4 installed. Does the “Missing Plug-ins” dialog bring you to Food4Rhino? Or does it launch the Package Manager? I guess I haven’t followed this dialog all the way through before, I just close it and get the missing add-ins from the Package Manager. This is also a good reminder for me to upload the latest to Food4Rhino.

Hi Brian -

Sorry about that, it looks like that fetches v0.4.2 from the Package Manager. So that should be good, yes.

Thank you so much for your advice. However, I still dont get a terrain…It is getting really frustrating now, that even my gh file that I created worked for you guys. So I have checked all you adviced me to check. I changed my rhino units from millimeters to centimeter and tried meters. I created a big square and did set one crv with the crv component. Still nothing happens…I have lost all hope.


I got this one to work now also!!! BIG PROGRESS! :smiley:
I dont know what I did to make it happen. I changed the units from mm to m, but still afterwards it changed back by itsel? So I had to double check again when I made my square crv to make sur it was in meters. Then still nothing happned, got some red components but after just changing between wireframe and shaded view in grasshopper it jumpstarted the whole thing and then it drew all the contour lines. Now I have my terrain of the location I needed.

So now the only last thing is how do I make it a “box” with the terrain as the top sheet of the box. I will save this as an STL file to mill it.

It has to look like this but should be a closed box.

Hi @Hobnob :slightly_smiling_face:
Try obtaining the API key from my last reply. It takes a minute to obtain it.
Then just use this example file together with that API key inputted to “Terrain Generator” component.

I have tried that too…
What should I do after I copied the API key?

Error message on component:


  1. The data you supplied to the “_geometry” input is neither a surface and/or polysurface and/or mesh.
    Please input some (or all) of these types of data to the “_geometry” input.


  1. Please supply the “terrain” output data from the Gismo “Terrain Generator” component, to this component’s “terrain" input.
    It needs to be a surface/polysurface: set the:
    ” input of the Ladybug “Terrain Generator” component to “1”, or
    “type_” input of the Gismo “Terrain Generator” component to “2” or “3”.

1 Like

Double click on “1” to set it to True.
This will create a 3D terrain.
Setting “2” is optional (analyse the terrain), and “3” (perform flow analysis on the terrain).

Also you can change the latitude_ and longitude_ inputs to correspond to your location.
Or just try first with these for Mount Vesuvius, just to test how components work.

1 Like

I got your gh file to work now! Unfortunately it could not make terrain of my location (Lochan Urr, Scotland) that I need to. I will perhaps try again tomorrow!

1 Like

It worked without issues.
I took the following latitude and longitude: 56.5988829, -5.0160719
With approximately 2 kilometers radius.
Attached is internalized geometry.

I used “Meters” as units, with 0.01 Tolerance.
SCT Lochan Urr 2km radius (1.4 MB)

1 Like

Is this possible to save as a STL file for CNC milling? The STL file will need the contour lines to be converted to surface I think…

Certainly. Rhino can export to STL file format.
But you can do that yourself.
What you have now in the attached .gh file is the actual terrain model:

But you would like to make it simplified, by converting it into a “stepped version” where each contour line is one slice so to speak? Like so? Did I understand that correctly?

You can extrude each contour line for a thickness which corresponds the distance between two contour lines (it should always be the same value for the whole model).

1 Like

No it actually does not need to be a stepped version. I can mill the smooth/rugged surfaces of the terrain with the CNC machine.

So it just need to be a sheet/surface with some thickness and a flat bottom. But I will ofcourse also need to scale down my model to 1: 10 000 because I do not have that big of CNC machine :smiley:

I still have not tried your advice in your latest reply to get my location. Will try it tomorrow!

Thanks for all the help so far!

1 Like

I made a “stepped” version from the upper attached .gh file.

I leave the export to STL to you, as I know nothing about the export settings.

SCT Lochan Urr 2km radius stepped3D (7.9 MB)

1 Like

Thank you! Appreciate it. But the modell will be fine as surface only without steps.


1 Like

Unfortunately the Gizmo method of creating a terrain seems to be to heavy for my computer. It crashed two times.

However I got @Brian_Washburn solution to work now and seems to be a modell both me and my computer can handle.

I am just wondering now why can I not snap a line or measure on the terrain?
I am trying to split it to make the bottom part flat, with the green line you see in the screenshot.
(I have created a surface of the contours with grasshopper components and then extruded the surface by klicking on it, and then pull down the surface, by holding ctrl down at the same time)

Will meshtonurb work to fix this? I get a warning message saying I have over 2000 meshes and my computer might run out of memory or crash. I am hesitant to press okey :sweat_smile:

Here are two ways to create a solid base from the topo surface, one produces a solid mesh, the other a solid brep. You can change the base depth to change the thickness of the base.
Glen Etive Topography_Solid Base (33.7 KB)


1 Like

Thank you @Brian_Washburn! This is very helpful.

I am just wondering why is the map texture not showing in this model? I need to draw small lake in the model which is not captured by terrain generator component. This lake is also what I will use to scale the terrain to 1: 10 000.

And also, why can I not snap a line or draw anything on the model? I might need to do some manual modifications.

Hi -

If the model is a mesh object, you need to make sure to enable Vertex in the OSnap panel.

1 Like

@Hobnob, if you set the “type_” input to “0” it will create terrain as a mesh, not brep.
That should be less heavy on your PC:

1 Like