Fractal Warp Shader

From Terragen Documentation from Planetside Software
Revision as of 22:55, 28 August 2020 by Redmaw (talk | contribs) (Updated documentation and example images to reflect latest parameters and version of the node.)
Jump to navigation Jump to search
Fractal Warp Shader
Fractal Warp Shader

Overview

The Fractal warp shader distorts the 2D texture coordinates of the upstream shaders connected to its Main Input. In the example below you can see the effect of modifying the Scale value on the black shape which is approximately 100 kilometers long. Practical examples of this might be to transform a shape defined and displaced by a Simple shape shader into a snaking river that cuts across the terrain, or into a detailed hill or mountain.

Fractal warp of 2D texture coordinates by only adjusting Scale value.
Fractal warp of 2D texture coordinates by only adjusting Scale value.
Simple shape warped into river terrain.
Simple shape warped into river terrain.
Simple shape warped into hill.
Simple shape warped into hill.


Node Type: Transform/Warp Shader


Settings:

  • Scale: Sets the size of the fractal pattern’s feature detail in meters and is similar to the Feature Scale parameter in a Power Fractal shader. Default value is 1000 metres and useful values depend on the size of the area to warp. Using too high a value relative to the size of the area you wish to affect, can result in unpredictable results as the fractal pattern can warp the areas to completely new positions and obliterate features. Values lower than the size of the area you want to warp can lead to more predictable results.
    Effect of changing Scale values over 1000 metres.
    Effect of changing Scale values over 1000 metres.
    Effect of changing Scale values over 1000 metres.
    Effect of changing Scale values over 1000 metres.


  • Warp amount: Sets the amplitude of the warp effect. Default value is 1.0. A value of 0.0 results in no warping effect. Lower values result in less warping, while higher values result in greater warping up to the limits set by the Scale parameter.
    Effect of changing Scale values over 1000 metres.
    Effect of changing Scale values over 1000 metres.
    Effect of changing Scale values over 1000 metres.
    Effect of changing Scale values over 1000 metres.


  • Variation:Visually adds random detail along the edge of the displaced areas. Negative values can break up an area into smaller and smaller fragments. A value of 0.0 should be avoided as it will cause all features to disappear. Increasing the value positively, reduces the amount of visual randomness, and the higher the value the more angular the effect becomes.
    Effect of changing Variation values over 1000 metres.
    Effect of changing Variation values over 1000 metres.
    Effect of changing Variation values over 1000 metres.
    Effect of changing Variation values over 1000 metres.


  • Roughness: This value determines how quickly a change or deviation can occur over the Scale of the warp fractal pattern. Lower values result in fewer deviations, subdivisions and segmentations of an area and visually look more angular. Higher values allow for more deviations, subdivisions or segmentation of an area, and visually look smoother and more random. The default setting is 1, and recommended settings range from 0 to 2.0.
    Effect of changing Roughness values over 1000 metres.
    Effect of changing Roughness values over 1000 metres.
    Effect of changing Roughness values over 1000 metres.
    Effect of changing Roughness values over 1000 metres.


  • Scale modulator: Accepts a shader as an input parameter to modify the Scale value. Where the scale modulator value evaluates to 0.0 no warp effect will occur, therefore this can act as a mask for the Scale parameter.
    Checker pattern as Scale modulator over 1000 metres.
    Checker pattern as Scale modulator over 1000 metres.
    Checker pattern as Scale modulator over 1000 metres.
    Checker pattern as Scale modulator over 1000 metres.
    Power fractal as Scale modulator over 1000 metres.
    Power fractal as Scale modulator over 1000 metres.
    Power fractal as Scale modulator over 1000 metres.
    Power fractal as Scale modulator over 1000 metres.


  • Obey downstream smoothing filters: Allows the Fractal warp shader to take into consideration the “Smoothing scale” parameter of any Smoothing filter shaders located downstream from it in the node network. The “Smooth scale” value can force the Fractal warp shader not to generate features smaller than the “Smooth scale” value thereby smoothing its output.
    Effect of enabling downstream Smoothing shaders over 1000 metres.
    Effect of enabling downstream Smoothing shaders over 1000 metres.
    Effect of enabling downstream Smoothing shaders over 1000 metres.
    Effect of enabling downstream Smoothing shaders over 1000 metres.


  • Mask by shader: When checked this shader is masked by the shader or function node assigned to this parameter.
  • Fit mask to this: If this is checked the mask shader, specified with the Mask by shader parameter is given different texture coordinates in order to remap it into the texture space of this shader. Note that not all shaders use texture coordinates so this may have no effect.
  • Invert mask: Check this to invert the values produced by the mask shader specified in the Mask by shader parameter.


Example Movies


Effect on displacement

Scale

Warp amount

Variation

Roughness

Effect on texture

Scale

Warp amount

Variation

Roughness