The Crack Network Tool
The use of the current
The crack width
New Povray scenes
provided for this tool
fun uses of this tool and the Povray scenes provided
The ability to create a close-looking imitation of a river bed or a
field fractured by drought is the starting idea for this tool.
The algorithms used in Geomorph for fracturing a terrain are mainly
inspired by the article Image-Guided Fracture, from
David Mould of the University of Saskatchewan. I adapted the concepts
and added some features, like the ability to raise the cracks edges so
that the surface looks like if it was shrinking when drying.
Because Geomorph is a design tool with which interactive feedback is
required, the process is basically "non-realistic". This is faster and
more creative than a real-world simulation process.
Depending on how you play with the parameters and from
which height field you start, you can get a convincingly realistic
result, or a fanciful one like cracks guided by a word.
From a realistic stance, when drying and cracking, an elastic surface
like mud gives more or less regular hexagonally shaped cells. On the
opposite, a non-elastic one like ceramic or most soils generally
produces rectangular cells. The Geomorph's crack network tool
hexagons, more or less regular. If you want rectangular cells, you can
use instead the "fault pen" , setting the difference in
altitude to 0
and drawing parallel / perpendicular cracks.
Notice that the crack network process can be slow, depending on the
if it's designed with an interactive use in mind.
Cracks are the boundaries of "cells". Differently stated, there is a
crack where the distance between two cell centers is equal.
Mathematically, Geomorph's crack networks are Voronoi diagrams.
The generation process is roughly this one:
The current height field is typically used as a noise function for
boundaries in an irregular way.
- Spill some amount of "seeds" on a surface. For instance, if an
average cell size of 10% of the surface size is chosen, the surface
being square, 100 seeds are scattered. The spacing of the seeds can be
more or less random.
- Use the pixels around each of these seeds as a boundary.
- Expand each boundary by running away from its parent seed.
- When an other boundary is encountered, stop. This common boundary
defines a crack.
The height field can also be used as a "guide" instead of a noise
grid. In that case, the higher values of the height field act as a
"fence" and forces a crack to appear. This allows, for instance, to use
letters as a guide.
When you choose in the tool dialog, you get this
- The average cell size
is specified in percent of the linear size of the image. For instance,
a 10% size gives
100 cells and 5% gives 400 cells.
- The seed controls
the pseudo-random generator, for any process requiring it, for instance
when the displacement of cell centers is calculated. If you start from
the same seed and the same image, you are supposed to get the same
- These subdialogs are detailed separetely:
- The edge raising
is used to emulate the shrinking of a drying surface. It is activated
only after the cracks are calculated when hitting Apply.
The examples are scaled down to half their linear size. In all cases,
with the default "subdivision 2" image, except when stated differently.
The seeds, which are the cell centers, are scattered in a random way.
More seeds are "spilled" in the center of the terrain. Cells are
smaller in the center. This gives more or less a "hammer blow" effect.
The spacing is proportional to the square of the distance from the
The seeds are regularly laid out on the surface. This
gives regular hexagons, with a slight vertical stretch.
The seeds are then moved
by a random amount, in a range specified by the user.
The example shows the effect of a random parameter of 0, 50 (default)
and 100 on a uniform grey image. If you use a height field as noise,
with the random parameter set to 0, the centers would be regularly
spaced, but the lines wouldn't be straight.
- The cell size is rounded to the nearest size for giving an
even number of cells rows, otherwise the bottom row would be irregular.
- The hexagons are slightly stretched to produce a tileable
height field. When rendering with Povray, scaling down the Z dimension
by 0.866 should give regular hexagons.
distribution (for uniform and centered cell distribution only)
This options repeats the cracking process at a lower level scale, using
level boundaries as a guide.
The example shows the effect of a 1x+2x+4x scale.
The crack width is 1 and the grid size
is 5% . First,
the program computes a crack net with a cell size of 20% (4x), with a
width of 4 pixels. On a second step, this net is reused for computing a
crack net with a cell size of 10% and lines of 2 pixels, inside the
bigger cells. The process is repeated a third time to compute 5% cells
into the 10% cells, with boundaries of 1 pixel width.
On a 512x512 grid, results are
better when using a size
less than 10% and a crack width of 1. In the case shown, the basic
crack width has been decreased from 2 to 1.
This can be a very long
process, particularly when noise is applied and a small cell size is
Rendering of a
multiscale crack network with cracknet_bumptest.pov
The use of the current
1. Using the
height field as a noise source
A height field used as a noise source locally
perturbs the cracks depending on the altitude value.
From left to right, the example shows what is produced
with a noise level of 0, 50 and 100.
2. Using the
height field as a "guide"
When using the "guide" option, the height field values are given a
greater weight than with the "noise" option.
This is mainly intended to be used with a height field showing steep
transitions from dark to clear areas. These transitions become
A check box allows to use a second height field to add some noise to
the cracks in the uniform background. This secondary height field is of
the "subdivision 1" kind. The seed and the roughness can be controlled.
The cracks width is specified in pixels. It is an absolute parameter,
so the resulting look depends on the size of the heigth field.
The width can also vary depending on the distance of the crack from the
cell center. The rationale is that cracks are created by the surface
tension, which makes the surface shrink until it "tears up". The
tension can be regarded as constant per unit of surface. When going
away from a cell center, the tension of
each unit adds up to its neighbours until a crack is encountered, so
that the shrinking
stress can be considered stronger when the distance of the crack from
the center of a cell is greater.
|Fixed width, 1 / 2 / 4 (512x512)
|Variable width, from 2 to 6 (512x512)
New Povray scenes
provided for this
Crack networks can be used as a standard height field in a Povray scene.
They can also be used as a bump map on an infinite ground plane, like
in the introductory image of this page.
In that case, the network is
tiled to fill the plane.
These new scenes are provided:
shows the current height field as a bump map on an infinite plane. It
tuned to be used with the default camera 3. This is the scene used to
render the multiscale example.
composite scene, using a ground map (the crack network) called group_map.png as a bump map and the
current height field rendered in the usual way. It was used to render the introductory landscape of this page.
composite scene using the crack network as a foreground height field.
It's more difficult to use than the former, because the crack network
is not tiled. Edges must be hidden, for instance by parts of the
background height field.
of cracknet_nobump.pov with a
2048x2048 ground height field
A new pigment map, maprock_redmud.inc
to work with these scenes. It is intended to reproduce sedimentary bands, when used as a
For using cracknet.pov, you
should start by defining a crack network and save it as ground_map.png. Then, you work on
your main height field, which can
be considered as a background terrain. A 512x512 height field is
sufficient for such a map.
Similarly, when using cracknet_nobump.pov,
you should start by saving your crack network as ground_map.png. In
that case, better results are obtained with a huge height field,
1024x1024 or 2048x2048. Cracking such a height field usually requires
enough time to prepare a coffee.
In both cases, you'll probably have to translate and scale both image
objects in the Povray file to get a convincing result. As usual, these
parameters are grouped at the end of the file, after the "**********"
Notice that the scenes do not have to be used with a crack network.
Interesting results can also be produced, for instance, by using a wavy
height field as the ground. Check this page.
Some additional hints:
This package contains further
examples. One of these examples features trees
generated with the java program Povtree. Another one is the
introductory scene of this page adapted to be rendered as an height
field instead of a map.
- For all scenes, begin with the default camera 3.
- For larger cracks, results are more natural after smoothing the
crack network with a radius of 1, or more with huge height fields.
fun uses of this tool and the Povray scenes provided
1. Write a word
The image at the top of this page uses
the word Geomorph as a guide.
For this purpose:
- Start with a black height field ("uniform" - the
field - at 0% level).
- Choose the "draw" subdialog and write your text with a small
pen at its maximum level. With a
512x512 map, the smallest size
(radius of 2) gives the best result.
- Go back to the "edit" subdialog to choose
the crack network tool, and set the height field use to "guide" instead
- For thinning your letters, you can use the "crest" tool .
- For sharpening your letters, you can use the "threshold" tool to
cut the range, and so cut the blurring, then use the "brightness /
contrast" tool to raise the constrast to the max,
using the "auto"
2. Using a crack
width of 0
Try to set the crack width to 0 and the edges level to 100%, then
revert the result. You will get something like this:
With sea_and_fog.pov, non
eroded and eroded
3. Using an other
height field than a crack network as a normal map
Written in December 2006
Back to the