Struct noise::RidgedMulti [] [src]

pub struct RidgedMulti<T> {
    pub seed: usize,
    pub octaves: usize,
    pub frequency: T,
    pub lacunarity: T,
    pub persistence: T,
    pub attenuation: T,
    // some fields omitted
}

Noise module that outputs ridged-multifractal noise.

This noise module, heavily based on the fBm-noise module, generates ridged-multifractal noise. Ridged-multifractal noise is generated in much the same way as fBm noise, except the output of each octave is modified by an absolute-value function. Modifying the octave values in this way produces ridge-like formations.

The values output from this module will usually range from -1.0 to 1.0 with default values for the parameters, but there are no guarantees that all output values will exist within this range. If the parameters are modified from their defaults, then the output will need to be scaled to remain in the [-1,1] range.

Ridged-multifractal noise is often used to generate craggy mountainous terrain or marble-like textures.

Fields

Seed.

Total number of frequency octaves to generate the noise with.

The number of octaves control the amount of detail in the noise function. Adding more octaves increases the detail, with the drawback of increasing the calculation time.

The number of cycles per unit length that the noise function outputs.

A multiplier that determines how quickly the frequency increases for each successive octave in the noise function.

The frequency of each successive octave is equal to the product of the previous octave's frequency and the lacunarity value.

A lacunarity of 2.0 results in the frequency doubling every octave. For almost all cases, 2.0 is a good value to use.

A multiplier that determines how quickly the amplitudes diminish for each successive octave in the noise function.

The amplitude of each successive octave is equal to the product of the previous octave's amplitude and the persistence value. Increasing the persistence produces "rougher" noise.

The attenuation to apply to the weight on each octave. This reduces the strength of each successive octave, making their respective ridges smaller. The default attenuation is 2.0, making each octave half the height of the previous.

Methods

impl<T: Float> RidgedMulti<T>
[src]

Trait Implementations

impl<T: Clone> Clone for RidgedMulti<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<T: Debug> Debug for RidgedMulti<T>
[src]

Formats the value using the given formatter.

impl<T> MultiFractal<T> for RidgedMulti<T>
[src]

impl<T> Seedable for RidgedMulti<T>
[src]

impl<T: Float> NoiseModule<Point2<T>> for RidgedMulti<T>
[src]

2-dimensional RidgedMulti noise

impl<T: Float> NoiseModule<Point3<T>> for RidgedMulti<T>
[src]

3-dimensional RidgedMulti noise

impl<T: Float> NoiseModule<Point4<T>> for RidgedMulti<T>
[src]

4-dimensional RidgedMulti noise