Intro: Converting Map Height Data Into 3D Tiles
In this Instructable I'll walk you through how to create a 3D tile from from map data. Its pretty straight forward but does require use of Terminal ( on OSX) or Command Prompt (on Windows)
Here are the basic steps:
- Find the area of the world that you want to 3D print
- Download the height data as a grayscale PNG
- Use a java script to convert the greyscale image into a STL
- Scale the STL
- Print on your machine of choice
- Print more!!!
Step 1: Find the Area of the World You Want to Print
Using the awesome terrain.party tool you can easily select a square portion of the world you want to print.
- Zoom out and click and drag the blue grid to part of the world you are interested in
- Zoom in to the scale you like (by double clicking or using the left hand side zoom tool)
- Then drag the blue grid around until in covers the area you want
- You can increase or decrease the size of the blue grid by clicking the + or - signs on the right hand sie
- Click the download icon on the right hand side (arrow in a cloud) to save the grid as a PNG
Step 2: Download the Height Data As a Grayscale PNG
Once you have download the data from terrain.party, uncompress the zip file.
Inside you will find a series of greyscale images. The white areas represent elevated ground and the black areas low level ground.
There are few different images, I use the (Merged) PNG.
Step 3: Use a Java Script to Convert the Greyscale Image Into a STL
Save the Heightmap2stl.jar file into the same directory as the previously download greyscale height images.
Now open Terminal on OSX (for Windows you can use Command Prompt and I think the commands are the same)
- Check what version of java you have by typing "java -version", it should come up with the following
java version "1.6.0_65"
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode)
- If your java is an older version, download the latest one here
- Navigate to the directory with the Heightmap2stl.jar script and the greyscale image, using the command
cd "insert path to directory here"
- Launch the script using this command, make sure you remove the ' ' around the path to imagefile and insert values for 'height of model' and 'height of base'. I used 100 and 10 respectively and it seemed ok.
java -jar heightmap2stl.jar 'path to imagefile' 'height of model' 'height of base'
- It should crunch the numbers for while then spit out a STL in the same directory
Step 4: Scale the STL
I'm going to use Meshmixer to scale my STL. Its free and it also great for preparing the STL for 3D printing.
Using the transform tool (or the configure tool) scale your model to the size you want, then either export as an STL or send directly to your 3D printer.
Step 5: Print on Your Machine of Choice
Step 6: Decorate!
I used some chalk board pens to colour the surfaces.
I highlighted the valleys green by using a green colour on the top surface then used a paper towel to wipe the excess ink off. I then applied a blue colour to the back surface to get the two tone finish.