====== Noise ====== Each land type includes several noise parameters that are used to add subtle randomness to the position of land types. Typical uses of such noise include: - 'Fraying the edges' at an interface between one type and another. - Adding random 'patchy' variation, such as switching from grass1<->grass2. - Making random clumps of rocks. The noise parameters are accessed from the [[l3dt:userguide:climates:ltedit:pane2|parameters tab]] of the [[l3dt:userguide:climates:ltedit|land type editor]] dialog, by clicking on the 'Noise...' button. The //noise settings// dialog box looks a little something like this: {{ :l3dt:userguide:dialogs:lt_noise.png |:l3dt:userguide:dialogs :lt_noise.png}} The meaning of the various settings are explained below: ===== RandAmp ===== //RandAmp// is essentially the strength of 'static' random noise (such as you get on an untuned TV set) that effects the score of the land type. If this value is used, it is normally set to a very small value (eg. 0.001). Technically, //RandAmp// is the [[#amp|amplitude]] of a Perlin generator that is hard-coded with just one [[#nOct|octave]] and a [[#Freq|frequency]] of 1. ===== Perlin1 and Perlin2 ===== Each type includes two [[l3dt:algorithms:hf:perlin|perlin generators]] (//Perlin1// and //Perlin2//). The three parameters for these generators (//[[#Amp]]//, //[[#Freq]]// and //[[#nOct]]//) are explained below. ==== Amp ==== The //Amp// value is the amplitude of the perlin noise generator. This is the maximum value that will be added to (or subtracted from) the land type score. Typically, these values are very small so as not to overwhelm the other [[l3dt:algorithms:cli:land_type:params|land type parameters]] (e.g. 0.01 to 0.0001). ==== nOct ==== The //nOct// value is the number of octaves to be used in the perlin generator. The effect of adding more octaves can be seen in the examples below:
| {{l3dt:algorithms:cli:land_type:perlin_1oct.png?250}} | {{l3dt:algorithms:cli:land_type:perlin_3oct.png?250}} | ^ 1 octave ^ 3 octaves ^ | {{l3dt:algorithms:cli:land_type:perlin_5oct.png?250}} | {{l3dt:algorithms:cli:land_type:perlin_10oct.png?250}} | ^ 5 octaves ^ 10 octaves ^
In the above example, the two land types ('red' and 'yellow') have identical parameters (BaseProg/grad/water/etc), but 'red' has non-zero settings for its //Perlin1// noise generator. Thus, the difference in distributions of the two land types is determined only by the noise settings. Please note: Using lots of perlin noise octaves makes the [[l3dt:algorithms:cli:am_algo|land type assignment]] algorithm //significantly// slower, so please use in moderation and with care. Also: To de-activate a perlin generator, set //nOct// to zero. ==== Freq ==== The //Freq// value is the spatial frequency of the largest-scale octave, relative to the size of a heightfield pixel. The effect of different frequencies may be seen below:
| {{l3dt:algorithms:cli:land_type:perlin1.png?200}} | {{l3dt:algorithms:cli:land_type:perlin2.png?200}} | {{l3dt:algorithms:cli:land_type:perlin3.png?200}} | ^ Freq = 1 ^ Freq = 0.1 ^ Freq = 0.01 ^ | (nOct = 1) |||
Typically, a //Freq// of 0.2-0.5 is used to 'fray' the interface between two land types. Please note that a //Freq// value of 1 is equivalent to using the [[#RandAmp]] value. Below is a more complex example, using both perlin generators and// RandAmp// (settings shown in dialog):
| {{l3dt:algorithms:cli:land_type:perlin4.png?300 }} | {{l3dt:algorithms:cli:land_type:perlin4_values.png}} |
One last example, demonstrating how to add random patches of of a land type (settings again shown in dialog):
| {{l3dt:algorithms:cli:land_type:perlin5.png?300 }} | {{l3dt:algorithms:cli:land_type:perlin5_values.png}} |
===== PerlinKey ===== //PerlinKey// is a random number (an integer) used as an offset in the Perlin noise generator. Its purpose is to ensure that the Perlin generators for each land type produce non-identical output. Normally you do not need to modify this value.