Jump to: navigation, search

Procedural texturing

No change in size, 13:45, 6 February 2018
Fix a typo
First, the overlay layer can support two different structures with different textures (for instance undergrowth and rock). The number 20 defines the texture for the primary layer, the number 21 for the secondary layer. The code makes an assumption that the secondary layer is smaller in height than the primary layer, so plan accordingly.
The first four parameters determine the apparent geometry of the overlay objects. All 'objects' (which really are painted on the shells only, remember) are based on Perlin noise to give them a pseudo-random appearance. <b><max_overlay_height></b> is the maximal distance the upper layer will be extruded from the ground - the largest of the random structures will reach to this level. As mentioned above, it's generally a good idea to keep this < 1 m (although the effect will run for higher numbers). The <b><overlay_hardness></b> is a number between 0 and 1 and determines how blurry the edges of the structures will be - generally for vegetation one wants a now low hardness, for rock (see below) a high hardness to get the illusion of a well-defined surface).
[[File:Overlay03.jpg|500px|center|Overlay layer used as rock]]

Navigation menu