Visit the original blog post at http://fragileearthstudios.com/2012/09/15/generating-complex-terrains/ for additional information and sample files. Forget what you know about editing terrains. Unlike the terrain editor in Unity that functions like a paint program, World Machine (and programs like it) operate on a procedural level. A World Machine world file is not the terrain, but the steps that creates the terrain. This is the source of both its power and its complexity. This presentation covers the process on how to use World Machine in conjunction with Unity3D to generate realistic looking terrains for your scene.
2. Preparation Download material from
the classroom web site
You should be
done with
this!
3. The World Machine Device
Program Variables
Inputs
World Machine operates Outputs
on a procedural level. A
World Machine world file
is not the terrain, but the
steps that creates the
terrain.
Input Mask
http://world-machine.com/learn.php
6. Perlin
Perlin Noise works by layering the output of
several sets of noise together. These layers are
called octaves. The multiple octaves are
combined together in a variety of ways to
create the final result.
7. Radial Gradient
The Radial Gradient
generator creates
shapes that are all
centered around one
point in space. (Ex:
spherical, gaussian,
diamond, square,
cone.)
8. Combiner
The combiner combines
two separate terrains
into one. There are a
variety of different
methods that can be
used to combine the
terrains -- each will give
a different effect.
9. Layout
A layout generator interacts with the
layout view to provide a home for a set
of shapes you can use to define terrain
shapes, create masks, add roads, and
more.
10. Erosion
The erosion filter simulates the work of thousands or
millions of years of weathering and erosion by rain,
flowing water and mass movement. It is an
exceptionally useful tool to add detail and realism to
human-created terrains. There are a large number of
parameters in the Erosion device and each parameter
can interact with the others to create to a unique
effect.
13. Select Slope
The slope selector is used to
create a mask that highlights
areas of the terrain that have
a particular slope. The output
will be full strength (white) in
those sloped areas and zero
strength (black) outside of it.
14. Select Convexity
The convexity selector discovers areas of the
input terrain that are either highly exposed
(convex) or recessed (concave). Convex areas
are white (one), while concave areas are black
(zero). Neutral areas that are neither will be
neutral grey. This device can be very useful for
texturing to either to help shadow recessed
cracks in the terrain, or to bring out ridges and
other areas that are highly exposed.
15. Select Height
The height selector is used to
create a mask that highlights
a certain height range of the
input terrain. The output will
be full strength (white) in that
range area and zero strength
(black) outside of it.
16. Probability Filter
The probability filter treats the input map as a
probability density function, and creates a
mask that randomly scatters dots according to
that density function. It is intended to be
useful for object placement maps.
17. Channel Combiner
The channel combiner recombines
three individual height fields into a
bitmap typically using the red, blue,
and green channels.
18. Splat Map
Terrain Distribution Maps
Grass Distribution
Tree Distribution
20. File Types
The file output device saves the fully built The bitmap output allows you to export a
height field to disk. Only the height field bitmap data type to a file. You may export
information is saved -- any color-height to either 8 or 16bit per channel color
mapping applied in World Machine is for formats.
illustration only, and is lost.
23. Scene Setup
The terrain paint tool is The tree placement tool is The grass and detail
expecting four textures for expecting three prefabs for placement tool is
the R, G, B, and Alpha the R, G, and B channels of expecting six grass or
channels of the splat map. the tree distribution map. detail meshes for the R, G,
and B channels of the
grass distribution maps.
24. Terrain Script
Drag the appropriate textures into the splat map, tree distribution, and grass/detail
distribution settings in “Julien’s Terrain Tools” and hit apply.
Forget what you know about editing terrains. Unlike many other terrain editors that function like paint programs, World Machine operates on a procedural level. A World Machine world file is not the terrain, but the steps that creates the terrain. This is the source of both its power and its complexity.This is the included sample file. Note the collection of devices which ultimately generate our terrain and associated bit maps.A free for non-commercial use version of World Machine is available for windows download at: http://world-machine.com/download.php
A device has Ports. A port is simply a place where terrain data can move in or out of a device. These can be divided into two main categories: inputs and outputs. Inputs are on the left side of the device, and bring data into a device to be acted on. After the action of the device takes place, the data is then taken out of the device via an output, on the right side. Lastly, some devices have a mask input port, which allows you to control the device's area of influence.There is one other type of port in World Machine, called a parameter port. These are located along the top edge of the device, and allow advanced users to adjust the settings of a device from a different one.
Green generates terrainBlue generates distribution mapsRed saves the output files
The devices used to generate the sample terrain height field. Distribution maps come later in the process.
This device is a highly customizable fractal terrain generator based upon the basic fractal noise techniques pioneered by Ken Perlin. http://www.world-machine.com/DeviceRef.html#APRL
Spherical: A sphere-shaped profile that falls off steeply at the edges.Gaussian: A mound-shaped profile that follows a gaussian distribution.Diamond: A constantly sloped profile that looks much like a pyramid.Square: A square profile. It stays level until dropping sharply at the edges to zero.Cone: Constantly slopes downward to zero in all directions.
Average: Average the two terrains together; the strength parameter controls the weighting of the average.Add: Add the 2nd terrain to the 1st. The strength control adjusts the amount of addition.Subtract: Subtract the 2nd terrain from the 1st. The strength control adjusts the amount of subtraction.Multiply: Multiply the terrains together. The strength control blends from none to full multiplication.Max: Use the tallest height of either terrain at each point.Min: Use the lowest height of either terrain at each point.Power: Exponentiate the 1st terrain with varying power based upon the 2nd.Root: Take the root of the 1st terrain with varying power based upon the 2nd. Values in the second heightfield above 0.5 are added to the first; if they're below that, they're subtracted.
Refer to chapter 5 in the world machine users manual for more information on the layout generator.
It is well worth your time to experiment either with your own settings or using one of the presets supplied with the device. Dramatically different effects and intensities of erosion can be achieved.
A heightmap or heightfield is a raster image used to store values, such as surface elevation data.
There is a controllable falloff amount that blends between the fully selected and fully-unselected areas. The slope sliders define a range of two slope. All areas with slopes between these two will be selected.Fuzziness Areas outside of the exact slope range specified will be partially selected based upon the strength of the fuzziness slider.Falloff TypeLinear: The fuzziness curve is a linear curve.Exponential: The fuzziness curve is an exponential curve (steep falloff at first, slow decay farther away).
Strength The Strength parameter determines what level of convexity maps to the largest allowable mask value.
There is a controllable falloff amount that blends between the fully selected and fully-unselected areas. Height Sliders The height sliders define a range of two heights. All heights between them will be selected.Fuzziness Areas outside of the exact height range specified will be partially selected based upon the strength of the fuzziness slider.Falloff TypeLinear: The fuzziness curve is a linear curve.Exponential: The fuzziness curve is an exponential curve (steep falloff at first, slow decay farther away).
Probability Type What kind of distribution model to use. There is currently only one option.Uniform: Use a uniform distribution to scatterthe points across the map.Bias The Bias control adjusts what value in the input map represents 50% probability of dot creation. The default is 0.5. Adjusting this will cause greater or fewer numbers of dots to be created.
The opposite of the Channel Splitter, this device can treat the three heightfields as either Red/Green/Blue or Hue/Saturation/Luminosity values.