Examples
14 |Below are a selection of examples made using this tools in Unreal Engine 5.1
15 |├── .babelrc ├── .gitignore ├── LICENSE ├── README.md ├── examples.html ├── index.html ├── instructions.html ├── package-lock.json ├── package.json ├── public ├── dist │ ├── 255db585f8a0eb28a1e4.svg │ ├── 2b3e1faf89f94a483539.png │ ├── 416d91365b44e4b4f477.png │ ├── 7a5643c730ac934189f5.svg │ ├── 7be8e3b179927ab7218d.svg │ ├── 8f2c4d11474275fbc161.png │ ├── css │ │ └── main.css │ └── js │ │ ├── app.js │ │ ├── main.js │ │ ├── main.js.LICENSE.txt │ │ ├── processor.js │ │ └── processor.js.LICENSE.txt ├── examples │ └── mt_fuji_8129.png ├── im │ ├── actual_error_grayscale.png │ ├── actual_error_terrarium.png │ ├── aizuwakamatsu_none.png │ ├── aizuwakamatsu_regular.png │ ├── aizuwakamatsu_smart.png │ ├── arrow.png │ ├── example_grand_canyon.png │ ├── grand_canyon_desserty.png │ ├── grand_canyon_desserty_2.png │ ├── grand_canyon_heightmap_sm.png │ ├── icon-down.png │ ├── icon-left.png │ ├── icon-marker.png │ ├── icon-right.png │ ├── icon-up.png │ ├── icons.ai │ ├── latlng_inputs.png │ ├── mapview.png │ ├── marker.png │ ├── mt_fuji_none.png │ ├── mt_fuji_regular.png │ └── mt_fuji_smart.png ├── test │ ├── 13-4092-2724.png │ ├── 13-4093-2724.png │ ├── 13-4094-2724.png │ ├── 13-4095-2724.png │ ├── 13-4096-2724.png │ ├── 13-4097-2724.png │ ├── bw16bit.png │ ├── terrarium.png │ ├── tiny16bitpng.png │ ├── tiny8bitpng.png │ └── tinyterrariumpng.png └── video │ └── grand_canyon.mp4 ├── rights.html ├── src ├── UPNG.d.ts ├── UPNG.js ├── app.ts ├── buffer.ts ├── helpers.ts ├── im │ └── Octicons-mark-github.svg ├── image.ts ├── main.ts ├── nextzen.ts ├── png.ts ├── processor.ts ├── sass │ ├── _overrides.scss │ ├── _variables.scss │ └── main.scss ├── templates │ ├── footer.html │ └── header.html └── types.d.ts ├── tsconfig.json ├── webpack.config.js ├── webpack.dev.config.js └── webpack.production.config.js /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["es2015-ie"] 3 | } 4 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Files 2 | 3 | .DS_Store 4 | .ruby-version 5 | npm-debug.log 6 | 7 | # Folders 8 | 9 | .idea/ 10 | .jekyll-cache/ 11 | .sass-cache 12 | _gh_pages 13 | _site 14 | node_modules 15 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2017 Jeremy Thomas 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Unreal Engine 16 Bit Grayscale PNG Heightmap Generator 2 | 3 | This is the source code the for the website that allows you to generate 16 bit grayscale PNG heightmaps easily in browser. 4 | 5 | You can find the website here: 6 | 7 | [https://manticorp.github.io/unrealheightmap/](https://manticorp.github.io/unrealheightmap/) 8 | 9 | If you feel like supporting this project, please consider donating! 10 | 11 | [https://ko-fi.com/harrymustoeplayfair](https://ko-fi.com/harrymustoeplayfair) 12 | 13 | We have started hitting the free tier limits from some map services, so the site *will not work* until we get some funding to up these limits. 14 | 15 | [](https://ko-fi.com/L4L212G6M7) 16 | -------------------------------------------------------------------------------- /examples.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 | 7 |Below are a selection of examples made using this tools in Unreal Engine 5.1
15 |The aim of this project is to generate 16 bit heightmap data for use in software such as Unreal Engine 5
18 |High quality height data is available from Mapzen's global elevation service.
19 |Using the map at the top of the screen, choose a location. You can also manually type in a latitude and longitude.
33 |The orange rectangle shows the size of the exported image, and what will be included.
34 |The size of the exported area depends on the output zoom and the output size in pixels.
35 |After clicking 'Generate' a 16 bit PNG should await you.
36 |Latitude | The Latitude at the centre of the image |
---|---|
Longitude | The Longitude at the centre of the image |
Zoom | The zoom level in the preview |
Output Zoom | The zoom level to use for the output |
Map Preview Type | The tiles to use in the preview at the top of the page |
Output Width (px) | The output width of the entire image in pixels |
Output Height (px) | The output height of the entire image in pixels |
Default UE5 Sizes | A preset list of useful sizes for generating Unreal Engine 5 terrain |
Normalisation Mode | The normalisation mode to use. See below for more information |
Norm From | Overrides the normlisation "from" parameter. Can be useful when low height data is funky, e.g. at the coast (just use 0) |
Norm To | Overrides the normlisation "to" parameter |
You can now copy and paste straight onto the page any lat/lng string. Acceptable formats include:
55 |The output will be a 16 bit grayscale PNG file with the gray levels representing the height of the ground at that location.
73 |16 bits gives 216 levels of detail between the lowest and highest point. That's 65536 levels - enough to detail from sea level to the top of mount everest (8849m) in roughly 13cm intervals.
74 |For comparison, 8 bit detail only give 28 levels of detail, which is only 256 levels!
75 |The mapzen data is actually much more detailed than 16 bit (it has 24 bits of data, with a fidelity of about 4mm in the data itself, although the measurements are probably only accurate to 1m maximum)
76 |When using the data for import into Unreal Engine 5, it can be useful to normalise the data so that you're using the full 16 bit range of the file.
80 |Normalisation Mode | 93 |None | 94 |Regular | 95 |Smart | 96 |
---|---|---|---|
Aizuwakamatsu Without Source Error |
101 | ![]() |
102 | ![]() |
103 | ![]() |
104 |
Mt Fuji With Source Error |
107 | ![]() |
108 | ![]() |
109 | ![]() |
110 |
Here is an example of an error in the source data:
114 |The heightmap data comes from NextZen, which was set up when Mapzen shut down.
18 |It is not 100% clear what the usage rights for the heightmaps are now. This was the "rights" page that appeared on the Mapzen site.
19 |This was their attribution guidance, specifically.
20 |If in doubt, the following snippet should be included on your project:
21 |© Mapzen, OpenStreetMap, and others.
22 |© <a href="https://www.mapzen.com/rights">Mapzen</a>, <a href="https://openstreetmap.org/copyright">OpenStreetMap</a> , and <a href="https://www.mapzen.com/rights/#services-and-data-sources">others</a>.
23 | All other maps should have a link to the copyright information on the bottom left of the map display.
27 |This data should be used for the "Export Albedo" type map data.
28 |Most map providers can be found on the leaflet providers page.
29 |