Difference between revisions of "Heightfield Generate"

From Terragen Documentation from Planetside Software
Jump to: navigation, search
(Combining multiple wiki pages for this node.)
Line 1: Line 1:
[[Image:drex_module_178_image_0.png|center|Heightfield Generate]]
+
[[File:HFGenerate_00_GUI.png|none|470px|Heightfield Generate]]
  
'''Node Description and Purpose:'''<br />
 
The Heightfield Generate node can be used to generate unique heightfield terrain based on a simple but powerful set of criteria. You can generate new heightfields based on fractals built into the node or you can use other shaders to generate height information for the heightfield. Use this for creation of heightfield terrains, especially in cases where you wish to apply heightfield-specific operations such as Erosion. Heightfields are of finite resolution and cover a specific area, unlike procedural terrains which have theoretically infinite detail and can cover an entire planet. However in Terragen 2 heightfields may be optionally rendered with procedural displacement to enhance detail. This is enabled by default.
 
  
'''Node Type:''' Heightfield Operator<br />
 
  
 +
== Overview ==
 +
The Heightfield Generate node can be used to generate unique heightfield terrains.  Heightfields are of finite resolution and cover a specific area, unlike procedural terrains which have theoretically infinite detail and can cover an entire planet.  Heightfields can be based on fractal patterns built into the node itself, or you can use other shaders to generate the height information. This node is especially useful in cases where you wish to apply heightfield specific operations such as Erosion.  Procedural displacement may also be used to enhance the detail of a heightfield via the Fractal Detail tab settings which are enabled by default.
 +
 +
'''Settings:'''
 +
* '''Name:''' This setting allows you to apply a descriptive name to the node, which can be helpful when using multiple Heightfield generate nodes in a project.
 +
* '''New heightfield:'''  When checked, or enabled, a heightfield’s resolution and size is generated using the “Number of points” and “Size in metres”  settings.  When unchecked, or disabled, a heightfield’s dimensions are taken from the nodes connected to the Input node.
 +
* '''Number of points: '''This sets the number of points, or resolution, of the heightfield.  The higher the value, the greater the resolution and more detail.  This setting does not control the area the heightfield covers.
 +
<ul>
 +
{|
 +
|-
 +
| [[File:HFGenerate_05_NumOfPoints10.jpg|none|266px|Number of points = 10]] || [[File:HFGenerate_06_NumOfPoints100.jpg|none|266px|Number of points = 100]] || [[File:HFGenerate_07_NumOfPoints1000.jpg|none|266px|Number of points = 1000 (default)]]
 +
|}
 +
</ul>
 +
* '''Size in Metres:''' This sets the X and Y size of the heightfield in metres, which determines the area covered by the heightfield.
 +
<ul>
 +
{|
 +
|-
 +
| [[File:HFGenerate_08_SizeInMetres2500.jpg|none|266px|Size in metres = 2,500]] || [[File:HFGenerate_09_SizeInMetres5000.jpg|none|266px|Size in metres = 5,000]] || [[File:HFGenerate_10_SizeInMetres10000.jpg|none|266px|Size in metres = 10,000 (default)]]
 +
|}
 +
</ul>
 +
* '''Generate at load time:''' When checked, or enabled, the heightfield will regenerate when a project is loaded.  This setting is enabled by default.
 +
* '''Generate Now:'''  Clicking this button will generate the heightfield.
  
'''Settings:'''<br />
 
  
 +
== Fractal Tab ==
 +
[[File:HFGenerate_01_GUI_FractalTab.png|none|470px|Fractal Tab]]
 +
The Fractal tab contains settings to let you define the main fractal pattern features used to generate the heightfield.
 +
* '''Feature scale:''' This setting controls the average size, in metres, of the features generated in the heightfield.
 +
<ul>
 +
{|
 +
|-
 +
| [[File:HFGenerate_11_FeatureScale500.jpg|none|266px|Feature scale = 500 metres]] || [[File:HFGenerate_12_FeatureScale2000.jpg|none|266px|Feature scale = 2,000 metres]] || [[File:HFGenerate_13_FeatureScale5000.jpg|none|266px|Feature scale = 5,000 metres]]
 +
|}
 +
</ul>
 +
* '''Feature steepness:''' This setting defines the steepness of the generated features. Higher values increase the steepness and height of the features.
 +
<ul>
 +
{|
 +
|-
 +
| [[File:HFGenerate_14_FeatureSteepness0p25.jpg|none|266px|Feature steepness = 0.25]] || [[File:HFGenerate_15_FeatureSteepness0p5.jpg|none|266px|Feature steepness = 0.5]] || [[File:HFGenerate_16_FeatureSteepness1.jpg|none|266px|Feature steepness = 1.0]]
 +
|}
 +
</ul>
 +
* '''Roughness:''' This controls the roughness of the generated terrain. Larger numbers are rougher.
 +
<ul>
 +
{|
 +
|-
 +
| [[File:HFGenerate_17_Roughness0p25.jpg|none|266px|Roughness = 0.25]] || [[File:HFGenerate_18_Roughness0p75.jpg|none|266px|Roughness = 0.75]] || [[File:HFGenerate_19_Roughness1.jpg|none|266px|Roughness = 1.0]]
 +
|}
 +
</ul>
 +
*'''Seed:'''  This setting controls the fractal pattern used by the node to generate the heightfield.  This allows you to easily create variations of the terrain based on the node’s other settings.  For example, you can define the “Feature scale” for the terrain and then explore variations on this theme by clicking on the “Random Seed” button which will change the Seed value.  Using the same Seed value in multiple Heightfield Generate nodes will generate the same pattern and heightfield.
 
<ul>
 
<ul>
<li>
+
{|
'''New heightfield:''' If this is checked the '''Number of points''' and '''Size in metres''' params are used to set the size and resolution of the heightfield. If this is not checked then heightfield dimensions are taken from nodes connected to the '''Input node''' input.
+
|-
</li><li>
+
| [[File:HFGenerate_20_Seed6035.jpg|none|266px|Seed = 6035]] || [[File:HFGenerate_21_Seed11979.jpg|none|266px|Seed = 11979]] || [[File:HFGenerate_22_Seed64118.jpg|none|266px|Seed = 64118]]
'''Number of points:''' This sets the number of points, or resolution, of the heightfield. This doesn't control the area the heightfield covers, that is done with the '''Size in metres''' param.
+
|}
</li><li>
 
'''Size in metres:''' This sets the X and Y size of the heightfield in metres. This is different to number of points in the heightfield as set above. '''Size in metres''' controls the area covered by the heightfield, whereas '''Number of points''' controls the resolution or detail of the heightfield.
 
</li>
 
 
</ul>
 
</ul>
 +
* '''Random Seed: ''' Clicking this button will randomly choose a new value for the “Seed” setting.
 +
  
<u>Fractal tab</u><br />
+
== Tweak Fractal Tab ==
 +
[[File:HFGenerate_02_GUI_TweakFractalTab.png|none|470px|Tweak Fractal Tab]]
 +
The Tweak Fractal tab contains settings that allow you to change additional aspects of the fractal pattern used to generate the heightfield.
 +
* '''Variation:''' This setting controls the distribution of the large and small features in the fractal pattern used by the node to generate the heightfield.  If set to “0” then both the large and small features are evenly distributed.  At higher values the fractal noise starts to vary less evenly, giving the pattern an increasingly uneven distribution between the large and small features.
 
<ul>
 
<ul>
<li>
+
{|
'''Feature scale:''' This parameter sets the average size, in metres, of the features generated in the heightfield.
+
|-
</li><li>
+
| [[File:HFGenerate_23_Variation0.jpg|none|266px|Variation = 0]] || [[File:HFGenerate_24_Variation1p5.jpg|none|266px|Variation = 1.5 (default)]] || [[File:HFGenerate_25_Variation4.jpg|none|266px|Variation = 4]]
'''Feature steepness:''' This sets the steepness of the generated features. Larger numbers make things steeper and will also increase the overall height of the features.
+
|}
</li><li>
 
'''Roughness:''' This controls the roughness of the generated terrain. Larger numbers are rougher.
 
</li><li>
 
'''Seed:''' This number controls the pattern generated by the node. If you use the same number in multiple Heightfield Generate nodes they will all generate the same pattern. The values of the parameters above can change the look of the terrain but the underlying patterns will be the same.
 
</li><li>
 
'''Random Seed:''' Clicking this button will randomly choose a new number for the '''Seed''' parameter.
 
</li>
 
 
</ul>
 
</ul>
 +
* '''Variation method:''' This popup menu provides three options for applying the "Variation" to the fractal noise pattern.
 +
<ul>
 +
[[File:HFGenerate_03_GUI_TweakFractalTab_VariationMethodOptions.png|none|351px|Variation Method options]]
  
 +
{|
 +
|-
 +
| [[File:HFGenerate_26_VariationMethodClampedMultifractal.jpg|none|266px|Variation method = Clamped multifractal]] || [[File:HFGenerate_27_VariationMethodUnclamped.jpg|none|266px|Variation method = Unclamped multifractal]] || [[File:HFGenerate_28_VariationMethodMultiscaleModulator.jpg|none|266px|Variation method = Multi-scale modulator ]]
 +
|}
 +
</ul>
  
 +
* '''Buoyancy from variation:'''  This setting adjusts how quickly the variation changes.
 
<ul>
 
<ul>
<li>
+
[[File:HFGenerate_29_Buoyancy.jpg|none|800px|Buoyancy examples]]
'''Auto generate:''' If this is checked the heightfield will regenerate when a project is loaded or when other parameters change. At this time it's recommended that you do not check this parameter.
 
</li><li>
 
'''Generate Now:''' Click this button to generate the heightfield.
 
</li>
 
 
</ul>
 
</ul>
  
==Additional tabs for Heightfield Generate==
 
  
* [[Heightfield Generate - Tweak Fractal Tab]]
+
== Use Shader Tab ==
 +
[[File:HFGenerate_04_GUI_UseShaderTab.png|none|470px|Used Shader Tab]]
 +
This tab contains settings which allow you to use a displacement shader to generate height information for the heightfield.  Clicking on the "Generate Now" button after assigning a shader will generate the heightfield.  If changes are made to the assigned shaders you will need to regenerate the heightfield.
  
* [[Heightfield Generate - Use Shader Tab]]
+
Using displacement shaders to generate heightfield data is useful in several ways. A heightfield may render quicker than a complex shader network. You can use it to "capture" the shader displacement in order to export a heightfield for use in another application. The heightfield won't have the same detail as the shader but it can be sufficient in many cases, for example as a low resolution stand-in terrain upon which to animate objects in another application. The exported heightfield could also be loaded into a heightfield editing application for further processing.
  
 +
* '''Shader:''' This lets you assign a shader to be used to generate height information.
 +
* '''Position center: '''If this is checked the origin of the shader assigned above is placed in the centre of the heightfield. The image below shows a heightfield generated Simple Shape Shader position in the centre. The origin of the Simple Shape Shader is at the centre of the shape.
 +
*'''Position lower left:''' If this is checked the origin of the shader assigned above is placed at the lower left of the heightfield. The image below shows the same Simple Shape Shader used in the image above, but this time it's placed at the lower left.
 +
* '''Position: '''This setting can be used to change the area of the shader which is used to generate the heightfield data. It's an offset from the origin of the shader. For example if you set the X field of the parameter to 500 the area of the shader covered by the heightfield is moved 500 m to the right.
 +
<!-- The following image shows a Simple Shape Shader placed at the top left of the generated heightfield using the Position parameter. The heightfield is 10000 x 10000 and the shader is 5000 x 5000. The shader is positioned using its centre. The Position parameter was set to 2500, -2500 to put the shader in that location. -->
 +
<ul>
 +
{|
 +
|-
 +
| [[File:Hfgen_shader_centre.gif ‎|none|262px|Heightfield shader centered.]] || [[File:Hfgen_shader_lowerleft.gif|none|262px|Heightfield positioned in lower left.]] || [[File:Hfgen_shader_offset.gif |none|262px|Heightfield positioned via Position settings 2500 in the "X" axis and -2500 in the "Y" axis.]]
 +
|}
 +
</ul>
 +
<br />
 
[[Category: Heightfield Operators]]
 
[[Category: Heightfield Operators]]

Revision as of 00:46, 4 February 2021

Heightfield Generate


Overview[edit]

The Heightfield Generate node can be used to generate unique heightfield terrains. Heightfields are of finite resolution and cover a specific area, unlike procedural terrains which have theoretically infinite detail and can cover an entire planet. Heightfields can be based on fractal patterns built into the node itself, or you can use other shaders to generate the height information. This node is especially useful in cases where you wish to apply heightfield specific operations such as Erosion. Procedural displacement may also be used to enhance the detail of a heightfield via the Fractal Detail tab settings which are enabled by default.

Settings:

  • Name: This setting allows you to apply a descriptive name to the node, which can be helpful when using multiple Heightfield generate nodes in a project.
  • New heightfield: When checked, or enabled, a heightfield’s resolution and size is generated using the “Number of points” and “Size in metres” settings. When unchecked, or disabled, a heightfield’s dimensions are taken from the nodes connected to the Input node.
  • Number of points: This sets the number of points, or resolution, of the heightfield. The higher the value, the greater the resolution and more detail. This setting does not control the area the heightfield covers.
    Number of points = 10
    Number of points = 100
    Number of points = 1000 (default)
  • Size in Metres: This sets the X and Y size of the heightfield in metres, which determines the area covered by the heightfield.
    Size in metres = 2,500
    Size in metres = 5,000
    Size in metres = 10,000 (default)
  • Generate at load time: When checked, or enabled, the heightfield will regenerate when a project is loaded. This setting is enabled by default.
  • Generate Now: Clicking this button will generate the heightfield.


Fractal Tab[edit]

Fractal Tab

The Fractal tab contains settings to let you define the main fractal pattern features used to generate the heightfield.

  • Feature scale: This setting controls the average size, in metres, of the features generated in the heightfield.
    Feature scale = 500 metres
    Feature scale = 2,000 metres
    Feature scale = 5,000 metres
  • Feature steepness: This setting defines the steepness of the generated features. Higher values increase the steepness and height of the features.
    Feature steepness = 0.25
    Feature steepness = 0.5
    Feature steepness = 1.0
  • Roughness: This controls the roughness of the generated terrain. Larger numbers are rougher.
    Roughness = 0.25
    Roughness = 0.75
    Roughness = 1.0
  • Seed: This setting controls the fractal pattern used by the node to generate the heightfield. This allows you to easily create variations of the terrain based on the node’s other settings. For example, you can define the “Feature scale” for the terrain and then explore variations on this theme by clicking on the “Random Seed” button which will change the Seed value. Using the same Seed value in multiple Heightfield Generate nodes will generate the same pattern and heightfield.
    Seed = 6035
    Seed = 11979
    Seed = 64118
  • Random Seed: Clicking this button will randomly choose a new value for the “Seed” setting.


Tweak Fractal Tab[edit]

Tweak Fractal Tab

The Tweak Fractal tab contains settings that allow you to change additional aspects of the fractal pattern used to generate the heightfield.

  • Variation: This setting controls the distribution of the large and small features in the fractal pattern used by the node to generate the heightfield. If set to “0” then both the large and small features are evenly distributed. At higher values the fractal noise starts to vary less evenly, giving the pattern an increasingly uneven distribution between the large and small features.
    Variation = 0
    Variation = 1.5 (default)
    Variation = 4
  • Variation method: This popup menu provides three options for applying the "Variation" to the fractal noise pattern.
    Variation Method options
    Variation method = Clamped multifractal
    Variation method = Unclamped multifractal
    Variation method = Multi-scale modulator
  • Buoyancy from variation: This setting adjusts how quickly the variation changes.
    Buoyancy examples


Use Shader Tab[edit]

Used Shader Tab

This tab contains settings which allow you to use a displacement shader to generate height information for the heightfield. Clicking on the "Generate Now" button after assigning a shader will generate the heightfield. If changes are made to the assigned shaders you will need to regenerate the heightfield.

Using displacement shaders to generate heightfield data is useful in several ways. A heightfield may render quicker than a complex shader network. You can use it to "capture" the shader displacement in order to export a heightfield for use in another application. The heightfield won't have the same detail as the shader but it can be sufficient in many cases, for example as a low resolution stand-in terrain upon which to animate objects in another application. The exported heightfield could also be loaded into a heightfield editing application for further processing.

  • Shader: This lets you assign a shader to be used to generate height information.
  • Position center: If this is checked the origin of the shader assigned above is placed in the centre of the heightfield. The image below shows a heightfield generated Simple Shape Shader position in the centre. The origin of the Simple Shape Shader is at the centre of the shape.
  • Position lower left: If this is checked the origin of the shader assigned above is placed at the lower left of the heightfield. The image below shows the same Simple Shape Shader used in the image above, but this time it's placed at the lower left.
  • Position: This setting can be used to change the area of the shader which is used to generate the heightfield data. It's an offset from the origin of the shader. For example if you set the X field of the parameter to 500 the area of the shader covered by the heightfield is moved 500 m to the right.
    Heightfield shader centered.
    Heightfield positioned in lower left.
    Heightfield positioned via Position settings 2500 in the "X" axis and -2500 in the "Y" axis.


A heightmap or heightfield is an array of height values, usually in a grid which describe the height at specific points in a defined area. Heightfields are used to represent real-world and virtual terrain in a specific, easily converted format. Most heightfields can be represented as simple image data in grayscale, with black being minimum height and white being maximum height.

Literally, to change the position of something. In graphics terminology to displace a surface is to modify its geometric (3D) structure using reference data of some kind. For example, a grayscale image might be taken as input, with black areas indicating no displacement of the surface, and white indicating maximum displacement. In Terragen 2 displacement is used to create all terrain by taking heightfield or procedural data as input and using it to displace the normally flat sphere of the planet.

A single object or device in the node network which generates or modifies data and may accept input data or create output data or both, depending on its function. Nodes usually have their own settings which control the data they create or how they modify data passing through them. Nodes are connected together in a network to perform work in a network-based user interface. In Terragen 2 nodes are connected together to describe a scene.

A shader is a program or set of instructions used in 3D computer graphics to determine the final surface properties of an object or image. This can include arbitrarily complex descriptions of light absorption and diffusion, texture mapping, reflection and refraction, shadowing, surface displacement and post-processing effects. In Terragen 2 shaders are used to construct and modify almost every element of a scene.

A parameter is an individual setting in a node parameter view which controls some aspect of the node.