Burning Pixel Productions
Line graphic
3ds Max Landscape Tutorial

by Ron K. Lussier

Terrain island
Image © 1998 Burning Pixel Productions - All Right Reserved

<Back

Tutorial #1

Creating procedural terrain meshes in 3D Studio Max 2+

Part 1 - Basic Formations

This tutorial is an explanation of the first part of some of the basic processes I have used to create 3D landscape files with 3D Studio Max 2+. It creates a mesh similar to the one in the image at the bottom of this file. Possible further additions to the Burning Pixel training materials may go into more detail on the procedures involved in creating and using 3D landscapes.


1.

Start with a Plane...

- Create a Plane
Make a 1200 unit square grid, set Length Segs and Width Segs to 50 and Density to between 2.0 and 4.0 (Use lower settings for faster test renders).

The Density: setting multiplies the segment count of the grid mesh when rendering. This greatly improves the definition of the landscape without slowing down the user interface, but it can take much more time to build in the "Preparing Objects..." phase of rendering.




2a. (optional step)

Add some initial Bitmap-based displacement for general height control. (Placing "mountains" and "valleys" where you want them.)

- Add a Displace modifier to the stack.
Create a grey-scale, heightfield image map and assign it with the Map: button, map-type Bitmap, and set Strength: to a few hundred. You can use Center Luminance to help keep the terrain from moving up so far as you adjust settings.



The Displace modifier is the key to this type of terrain generation process. It does all the placement of the vertices according to the Bitmap: and/or material editor Map: information from which you tell it to assign vertex "elevation" values.

In this case, we'll use this first Displace mod as a custom greyscale heightfield (image) in the
Map: slot for overall elevation control. Pure white equals 100% of the Strength: setting (in units), black equals zero. You could also do this through the Bitmap: slot, without creating a material, but you lose Tiling and Output control of the image data.

Grey-scale heightfield example...


2b.

Adding procedural displacement to get detailed surfaces...

- Add a second Displacement modifier to the stack.
Give it some Strength:, assign a Mix map to the Map: button, and drag an Instance of it into the Material Editor. The Mix map is more versatile than the Mask map, Mix can get similar results but with more control (via the Mixing curve), and also allows for adding a second map to the "negative space" of the Mask map.

(Next, in Step 3 we'll add sub-maps to the Mix map, to actually get some displacement happening.)


This is where we get to the important part of this process. 3D procedural mapping functions can usually achieve much more than you could with image maps alone. One reason for this is the lack of any seam or exact repetition in bitmap mapping, another is because of the complex, high resolution, multilevel material definitions that can be created in Max's materials.


3.

Add displacement Noise maps...

In Mat. Editor name the Mix map (from the Displace modifier) "DisplaceMaps".

In the Color #1 slot add a Noise map, name it "Small" and change the Size to about 160. Set Type to Fractal and Levels = 6.0  - we need some small detail on the terrain surface so it doesn't look too smooth. Be careful turning the Levels up like this though, it slows down calculations. Above 6 or 7 levels is not often necessary, as there is not usually a visible improvement (depending on the scale of the Noise function).

Go back up to the Mix map and add a Noise map to the Color#2 map slot, go into it, name it "Large" and Swap the 2 color swatches. Change the Size to ~600.  (I also set Noise Threshold: Low: 0.4  - to smooth the lower elevations, and Phase: 2.0) 

 Click on the Mask slot and Choose Noise, name it "Medium", size to ~300  (I also set Type: Fractal, Levels: 2.0, Phase 4.0).


If you turn on Generate Mapping Coordinates for the Plane object, and then set Use Existing Mapping in the second Displace modifier, you can get non-vertical displacement! - The originally flat mapping created by the Plane has been distorted by the first Displace modifier. The new surface normal direction will be used, as the direction to displace vertices, by this second Displace modifier.



4.

Adding altitude mapping for strata...

- Add a UVW modifier to the stack.
Click Box and increase the Height: value by about 20+ percent  then click back to Planar (this is to cover minor changes and the extra vertices created when rendering the mesh).




Mapping according to height can also be achieved by using the "Planar from Object XYZ" mapping choice in the materials editor, but doing it with a modifier gives you easier (visual) control over placement.

You can use the Mapping: Box setting to visually check the height of the mapping coordinates in the viewport, but be sure to change back to Planar!

If you make major changes to the height of the terrain you will need to update the Height value here to cover the taller mesh.


5.

Create a simple height based material.

- Assign a Standard material to the terrain object. Click on the Diffuse channel's map slot and pick Gradient.

To orient the map to the "altitude mapping" coordinates we've applied switch to WU and enter 90 in the Angle:, W: field.

For this example, the top will be snow-like (maybe mineral deposits), so leave Color#1 as white, make Color#2 a dark muted brown or gray and Color#3 a "sandy" tan color.

(Gradient) Noise Settings: Amount: ~0.5, type: Fractal, Size: ~0.5



This is just a quick map to give the mesh some semi-natural height variation. A completely seperate set of tutorials could be written on ways to texture map terrains.


6.

Tweaking the settings...

Try adding some "Grain" to the middle dirt/rock color and to the Sand by adding small scale Noise functions to color slots 2 and 3.

In the DisplaceMap's "Large" Noise map, try turning up the Low: Noise Threshold (as mentioned above). This will give you more prominent, and smoother, low areas in the landscape.

Add another small scale Noise in the Terrain material's Bump map slot to help break up the surface more. This helps the final image quite a bit. (Size ~5 or less... depends on how close the camera is to the surface.)

Try changing various settings in the displacement maps. Changing the Phase of the Noise maps can result in drastically different landscapes.

With some tweaking, a little atmosphere and lighting, you can end up with something like this...

 

landscape result

<Back


This tutorial is © Copyright 2000 Ron Lussier
All Rights Reserved - Do not re-distribute or reproduce.

3ds MAX is a registered trademark of Autodesk, Inc.



Burning Pixel Productions


Home   |  Info   |  3ds Max   |  Music   |  Photography   |  Vector Graphics   |  Dancing Baby   |
Graphics Gallery   |  3D Stereo Gallery   |  Brazil Gallery   |  QuotesBlog   |