Creating landscape textures and heightmaps using Terragen

I have recieved a question lately on how to take a landscape created with the excellent and free Terragen program to a Truevision3D TVLandscape, so I thought I’d make a small tutorial about it.

Preparing the terrain

I’m going to go fast on this because Terragen is pretty intuitive, and there are numerous tutorials on how to actually make the landscape.

Making the heightmap

  • First you need to make a heightmap in the Landscape dialog.

  • To do so, click on the Generate Terrain... button (highlighted in the screenshot), choose the appropriate settings in the Terrain Genesis dialog, select whichever settings you like and press on Generate Terrain button of the new dialog.
  • After you’re done with the heightmap, it’ll appear in the Landscape dialog. Click on Close to return to it.

Making the surface map

  • There are several pre-made surfaces coming with Terragen, you can choose them with the Open... button in the Landscape dialog. Otherwise, you can add children surfaces to the base surface, set their color and their area of effect. The trick is to play with it, and this is not the focus of my tutorial.
  • Although there is one thing I’d like to add that may make your surface-making easier. There is a plug-in pack called SOPack that adds bitmap-loading capabilities (among many other things) to Terragen; this allows your surfaces to be not only solid-colored, but also textured and tiled. Learn about it here : http://www2.cs.uh.edu/~somalley/sopack.html

Preparing the camera and atmosphere

There are a couple of Terragen settings that we need to change for the orthographic (top-down view) rendering of the landscape to look good.

Rendering and camera control

  • First you can disable the Sky, since we won’t be rendering it, and it may speed things up
  • For the final render, you can push the rendering detail to maximum
  • Then click on Camera Settings...
  • The bottom dialog will appear; choose Orthographic and click on Auto Setup..., and answer Yes to the dialog
  • Close the camera settings dialog. The values in the rendering dialog should resemble those in the screenshot

Atmosphere setup

  • Normally, there is a very cool atmospheric haze effect, but since we’ll far atop of the landscape, we must disable it not to get blueish colors.

  • Set all Density sliders to 0% in the Atmosphere dialog
  • Disable Clouds Cast Shadows and Shadows In Atmosphere if they’re enabled
  • If you want to have dynamic lightning on your landscape (i.e. a moving sun), you should put the Sun Altitude to 90. Obviously that’ll cancel the pretty shadows, but with the terrain normals in TV3D you’ll get nice lightning nonetheless.

Saving the maps

Saving the heightmap

  • It’s a bit of a hack, but the only way I’ve found to save a heightmap from Terragen is to take a screenshot of it.

  • In the Landscape dialog, click on View / Sclupt... and you’ll get a 512×512 image of the landscape.
  • The take a screenshot using ALT+PrintScreen
  • Open your favourite image viewer/editor (Photoshop, GIMP, IrfanView...) and crop out everything but the heightmap
  • Save the resulting image as a BMP, JPEG, DDS, whatever you feel like; TV3D is a pretty versatile image opener!

Saving the texture map

  • The texture map will actually be the render, using the orthogonal camera settings that we’ve set before

  • In Render Settings of the Rendering Controls dialog, you can turn on and off the quality settings... Since we won’t be rendering the atmosphere nor the clouds, you can turn those off. The other options might be disabled if you’re using a non-registered version of Terragen, but they make the sampling look better
  • Then choose the image size. The largest size for the unregistered version is 960×960, but in registered mode you can choose the graphic cards’ maximum for one texture, 2048×2048, for it to look best
  • Finally, click on Render Image and the image will start rendering. This could take a while...
  • When it’s done, click on the Save button, and choose the place to save the BMP texture. You can use any image editor to convert the image to your favourite format, though for a texture of that size I’d strongly suggest using a DDS file format with DXT1 compression.

Final result

That’s it, you’ve got a texture and a heightmap, now you can load those in a landscape with a nice generic detail texture, and get results like those!

 
tutorialsarticlesandexamples/create_a_landscape_in_terragen.txt · Last modified: 2013/11/22 13:32