How To: Generate Superb Heightmaps :)

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

Post Reply
peterj
Engineer
Engineer
Posts: 3
Joined: 09 May 2007 10:49

Post by peterj »

i am trying to make a good map of western europe and have been following this tutorial to the letter... but when i come to make the grayscale image 1:1 my comp. doesnt have enough resources. Can anyone help me finish this off or link me to a good heightmap of Western Europe. I am looking for including UK up to italy and some of north africa. See image attached. Pref 2048 x 2048 or 1024 x 1024...
Attachments
EUROPE.PNG
EUROPE.PNG (39.35 KiB) Viewed 15438 times
User avatar
Irwe
Chief Executive
Chief Executive
Posts: 763
Joined: 25 May 2007 16:31
Location: Sweden

Help I dont understand

Post by Irwe »

SRTM Overlay for GoogleEarth (Run from URL once you've installed Google Earth... what is URL? I am not so good at computers and I dont know what URL is plz help me.
User avatar
Bob Smith
Engineer
Engineer
Posts: 111
Joined: 17 May 2005 23:25

Post by Bob Smith »

peterj - that's quite a serious request, 35 sets of data are needed to be downloaded and merged. Perhaps if I get bored enough tomorrow...

In the meantime I've been playing with this all day, this is really neat! Much better than when I tried doing this before (which was 2 years and 2 days ago).

Here are a few I've whipped up to day: http://bmp.thefloatingwidget.net/heightmaps/

So far Cyprus, Madagascar, New Zealand and the UK (plus some parts of the UK further zoomed in)

Italy (and surroundings) and (Eastern) Canada to follow tommorow. :)


Edit:
Oh an update to the guide:

"To do this, select File->Save DEM->Thin DEM (Decimate)."
is now:
"To do this, select Raster GIS->Thin DEM (Decimate)"
peterj
Engineer
Engineer
Posts: 3
Joined: 09 May 2007 10:49

Post by peterj »

yea i realise this is a mean request. I downloaded all the sets of data and spent most of a weekend to get it all perfect and just when i was nearing the end i suddenly had a lack of resources message. I went home recently and tried to do it on my dads big computer but i got the same message.

Is there any way of doing a simpler quicker version. I made a PNG of europe from the world height map supplied by someone earlier in this topic... but I can't quite get the shadings right to make the heights right... it seems very high land and sea level are the same colour for some reasons ???!?!?
User avatar
Bob Smith
Engineer
Engineer
Posts: 111
Joined: 17 May 2005 23:25

Post by Bob Smith »

No idea about the other data, but if you thin the data more as described it this guide, that should lessen the resouces needed. With an area that large you could thin by 6 and the final TIFF should still be greater than 2048x2048.

Oh, Eastern Canada and Italy are done now.
User avatar
Dave
Moderator
Moderator
Posts: 17243
Joined: 26 Dec 2005 20:19
Location: North London

Post by Dave »

Any chance of a heightmap of the West Midlands?

Terribly demanding. Apologies.

I've been planning a game for a while now, based on the Black Country.
Official TT-Dave Fan Club

Dave's Screenshot Thread! - Albion: A fictional Britain
Flickr


Why be a song when you can be a symphony? r is a...
User avatar
thebrightside
Engineer
Engineer
Posts: 78
Joined: 28 Feb 2007 15:35
Location: The Netherlands
Contact:

Post by thebrightside »

Post or PM me exactly what you want included on the map. So which towns, rivers, hills etc. So I can get you a good cut heightmap just for your needs.
adam
Engineer
Engineer
Posts: 1
Joined: 18 Jul 2007 21:21

Re: How To: Generate Superb Heightmaps :)

Post by adam »

Hi all first post here, not really sure if this is the place to do this but, I was wondering if someone could make a heightmap of the US state Minnesota. I would do it myself but my computer is not very powerful as was recommended. Thank you
User avatar
shampie
Engineer
Engineer
Posts: 120
Joined: 13 Feb 2005 01:13
Location: Eindhoven - Netherlands Ottawa - Canada

Re: How To: Generate Superb Heightmaps :)

Post by shampie »

Hey,

I've taken a picture of a couple of clouds (little fluff's) and changed the colours to grayscale (PS CS2)
then I changed what used to be the clear blue sky to totally black and read it in openttd.

Here is the scenario.

Total Population (1940): 6,970

-Shimora
Capital: Mytharoom (1,162)
Population: 3,264 (17 Towns) (avg. 192/town)
Major Industry: Mining
Economy: Average
Max height: 500m + (Mountainous)

-Stoja Egh Astaforia
Capital: Dhallstowen ( 1,236)
Population: 3,706 (15 Towns) (avg. 247/town)
Major Industry: Production
Economy: Average
Max height: 300m + (Hilly)
Attachments
Shampzaar.scn
Scenario
(89.86 KiB) Downloaded 349 times
Map of Shamzaar
Map of Shamzaar
map.png (141.33 KiB) Viewed 14032 times
Last edited by shampie on 02 Aug 2007 17:15, edited 2 times in total.
To express moral judgments about good and evil, you must posit that good and evil exist
If good and evil exist, you must posit a moral law by which we can distinguish between good and evil
If a moral law exists, a moral law giver must exist.
User avatar
thebrightside
Engineer
Engineer
Posts: 78
Joined: 28 Feb 2007 15:35
Location: The Netherlands
Contact:

Re: How To: Generate Superb Heightmaps :)

Post by thebrightside »

In version 0.5.2 I get game load fail.
In r10620 I get game load fail. Broke save game. Unknown chunk type...

So unfortunately not able to play it. What version did you use? And what size is it anyway? Any grf files used?
Geographer in making
My Scenarios
User avatar
shampie
Engineer
Engineer
Posts: 120
Joined: 13 Feb 2005 01:13
Location: Eindhoven - Netherlands Ottawa - Canada

Re: How To: Generate Superb Heightmaps :)

Post by shampie »

This is for nightly r10737, no newGRF's used.
See if that works for you.
G'luck
LordAzamath
Tycoon
Tycoon
Posts: 1656
Joined: 08 Jun 2007 08:00

Re: How To: Generate Superb Heightmaps :)

Post by LordAzamath »

You can generate heightmaps with GIMP too. they just become very hilly. Like arctic. Have to apply solid noise to the pic, you want and then gradient map with gradient land and sea selected. There are more native gimp gradients you can chhos, though. And you can alwys make a new gradient. Maybe at start you have to duplicate the solid noise layer to make later a bump map. Easier way, though is through the gimp main window Xtns->Patterns->Land/Flat land, Render Map
PS: And I stopped the propaganda to support Dave Worley since he got a nice new red hat now.[/color]
I know I have a BBCode error in my signature but I really cba to fix it.
User avatar
DJ Nekkid
Tycoon
Tycoon
Posts: 2141
Joined: 30 Nov 2006 20:33

Re: How To: Generate Superb Heightmaps :)

Post by DJ Nekkid »

the guide seems somewhat outdated? or the version/interface of the software has changed...
Member of the
ImageImage
User avatar
Yeebaagooon
Engineer
Engineer
Posts: 8
Joined: 15 Sep 2007 20:50

Re: How To: Generate Superb Heightmaps :)

Post by Yeebaagooon »

Brilliant guide!

Easy to understand with amazing results.
okdewit
Engineer
Engineer
Posts: 54
Joined: 30 Sep 2007 21:55

Re: How To: Generate Superb Heightmaps :)

Post by okdewit »

I would love to experiment with this...

MicroDEM gives me I/O Error 104 as soon as I try to load a .ASC file...
Anyone same problem, or even better, know the cause?
Image
Nehacoo
Engineer
Engineer
Posts: 1
Joined: 02 Oct 2007 16:57

Re: How To: Generate Superb Heightmaps :)

Post by Nehacoo »

I'm having the same problem as okdewit, although sometimes I get "Access violation at address 008828BE in module 'microdem.exe'. Read of address 00000001."

One thing that I noticed is that the guide refers to the SRTM thingie as SRTM2. The one I got from that link was called SRTM3.KMZ, so it seems it has been updated. Could this be the cause?
okdewit
Engineer
Engineer
Posts: 54
Joined: 30 Sep 2007 21:55

Re: How To: Generate Superb Heightmaps :)

Post by okdewit »

Yes it is! (SRTM2 is now considered "obsolete" and upgraded to v3, which is incompatible with MicroDEM)

Experimented a little, and I found an easy solution for this:
  • Open Google Earth
  • Load the SRTM Layer as instructed
  • Download the GEOTIFF file instead of the ARC-ASCII File.
  • Load the GEOTIFF in MicroDEM (File --> Open DEM)
You can export the DEM in ASC (SRTM2) format to use it with the ingame ASC importer patch, or convert it to png like described in this tutorial.

EDIT: Apparently, it's impossible to do Data Manipulation --> Merge on a geotiff. Somehow, if I export them to ASC format, MicroDEM can't open them anymore (same I/O error or Memory error).
Looking into it right now. (perhaps version difference of SRTM isn't the cause after all?)
Image
Bazhosh
Engineer
Engineer
Posts: 10
Joined: 02 Oct 2007 23:15
Location: Germany
Contact:

Re: How To: Generate Superb Heightmaps :)

Post by Bazhosh »

Try this:
http://www.usna.edu/Users/oceano/pguth/microdem.exe

This version seems to work.
okdewit
Engineer
Engineer
Posts: 54
Joined: 30 Sep 2007 21:55

Re: How To: Generate Superb Heightmaps :)

Post by okdewit »

Thanks a lot, with that executable I can actually load the .asc files :D

Merging is somehow still disabled (grayed out) :roll:
...and the netherlands seems to be the worst country to make a heightmap of... the coastline of the flevopolder is not even visible :(

I hope people will post some high-res scenario's (> 2Kx2K :D)

Thanks for all the help.
Image
nb-au
Engineer
Engineer
Posts: 24
Joined: 10 Oct 2007 08:20
Location: NSW, Australia

Re: How To: Generate Superb Heightmaps :)

Post by nb-au »

For Linux:

You will need the following:

* Google Earth (http://earth.google.com) [sh googleearth.bin to install or use repos]
* SRTM Overlay for GoogleEarth (http://www.ambiotek.com/topoview). Loading this from the web sometimes made GE crash, just save it to hd
* GDAL Utilities- Geospatial Data Abstraction Library Utilities (http://trac.osgeo.org/gdal/wiki/DownloadingGdalBinaries) [install from site or via repos ("gdal-bin" package)]
* A graphics program, such as The GIMP

I run an A64 x2 6000+ w/ 4GB RAM, this took next to no time, tho YMMV

Google Earth
*Start Google Earth
*Load the SRTM kmz file
*Click on the Green buttons and you'll see a page pop up, scroll to the start of the links and you'll want to download either of the first two links (Either from the US or UK Servers, it doesn't matter), its the data file in ARCASCII format.
*Save the files

GDAL Utilities
*Open a terminal window.
*Type:

Code: Select all

gdal_translate -of PNG -ot byte -outsize 2048 2048 INPUTNAME.ASC OUTPUTNAME.PNG
Replacing the names of input and output file with your own choice, outsize can also be changed [for best results to a size ready for OpenTTD] though 2048x2048 gives the best results IMHO
*Wait for it to complete (took me only a couple of seconds, YMMV)
*Further usage instructions can be found at: http://www.gdal.org/index.html if you want to do any other stuff to your files.

The GIMP (Optional)
At this stage you have a greyscale PNG, which works great in OpenTTD.
If your sealevels are whacky then you need to do some editing in The GIMP. Select the sea [magic selector with 0 tolerance] and invert the selection [so that the land is selected], and adjust the brightness until prefered results are obtained. Some areas may have to be fixed manually in OpenTTD, but at this point you should have a perfect or near perfect map of your area of choice.

If you want you can also crop out only the parts you want into another PNG using the supplied tools, again for best results size them to an OpenTTD standard size.






GDAL Utilities also work in Windows and Mac, so similar instructions could be used there.
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: No registered users and 14 guests