VRML Shockwave 3D
Home Books Applications Tools Docs Models Textures

Please send me your comments
Tutorials List

Terrain Tutorial

Index

Introduction

A TGA Library
A Simple TGA Library
TGA lib Source

Height Maps
Height Maps from Images

Lighting
Computing Normals
Simulating Lighting
Implementation Details
Screen Shots

Source Code

Artificial Terrain Generation
The Fault Algorithm
Implementation Details
Two Simple Variations
The Circles Algorithm

Mid Point Displacement
The MPD Algorithm

Particle Deposition

Smoothing
Smoothing
Matrix filters
API details

Source (Linux and Win32)

[Previous: Implementation Details] [Next: Circles Algorithm]

Terrain Tutorial


Two Possible Variations


In the previous sections we considered that points on one side of the line would have their heights increased, whereas the other points would have their heights decreased by a constant amount. This is equivalent to applying a step function based on the distance from the point to the line.

By swapping the step function it is possible to obtain interesting landscapes. For instance we could use a sine function as the figure bellow:

In this case the surface will look smoother than with the step function. The next figure shows a single iteration using the sine function:

Another interesting replacement for the step function is a cosine function as the one in the figure bellow:

A single iteration with this function will look like:

The following figures show results obtained after 1000 iterations with all three functions.

Step function

Cosine function

Sine function

Use up your imagination to come up with other functions and let me know if you get interesting results.

[Previous: Implementation Details] [Next: Circles Algorithm]



Site designed and maintained by António Ramires Fernandes
Your comments, suggestions and references to further material are welcome!

Lighthouse 3D privacy statement