Build HSV Colour

From Terragen Documentation from Planetside Software
Revision as of 23:23, 21 March 2022 by Redmaw (talk | contribs) (Updated descriptions and added example images.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Build HSV


Overview[edit]

The Build family of nodes allow you to construct colours or vectors. They let you input scalar values for each component. For the Build HSV node you can input values for Hue, Saturation, and Value.

Values from the Main Input are used as the basis for building the new value. If you do not assign a node to one of the other inputs, Hue, Saturation, or Value, then the value for that component is taken from the corresponding component from the Main Input. Here is an example, using a vector:

Input.x is 100
Input.y is 200
Input.z is 300

X scalar input is 500
Z scalar input is -400

The output vector will look like this:

Output.x is 500
Output.y is 200
Output.z is -400


As there is no scalar input for the Y component the y value from the input vector is used. Here is a diagram of the example above:

Build colour vector network.jpg


In the example images below, no shader or function nodes are assigned to the Main input. You can see how the Hue, Saturation, and Value results change as the value assigned to each input in increased from 0 to 1.

As the Hue value increases from 0 to 1 the colour value changes.
As the Saturation value increases from 0 to 1 the intensity of the colour increases.
As the Value parameter increases from 0 to 1 the brightness increases.


In the following example, a Constant colour node serves as the Main input, while the values assigned to Hue, Saturation, and Value inputs are increased from 0 to 1.

Constant colour node assigned to Main Input.
As the value increases, the Hue shifts according to the Main input’s colour values.
At a value of 0 the colour is completely desaturated, while at a value of 1.0 the colour is fully saturated.
At a value of 0 the colour is completely dark, or black. As it rises towards 1, the colour brightens.


Settings:

  • Name: This setting allows you to apply a descriptive name to the node, which can be helpful when using multiple Build HSV nodes in a project.


  • Enable: When checked, the node is active and the conversion operation will take place. When unchecked the values assigned to its Main Input, if any, are passed through, otherwise a value of 0 is passed through.


  • Hue input: The shader or function nodes assigned to this setting determine the colour of the output. You can think of the recommended values, 0 to 1, as shifting along the colour spectrum or rotating around a color wheel. If a value of 0 represented the red hue, a value of 0.5 would be 180 degrees opposite it, a Cyan colour, on the colour wheel.
    Node network view illustrating Build HSV supplying colour values to surface.
    Render illustrating the Build HSV supplying colour values to a surface.


  • Saturation input: The shader or function nodes assigned to this setting determine the saturation of the hue. A value of 0 is desaturated, while a value of 1 is fully saturated.
    Node network view illustrating Build HSV supplying saturation values to surface.
    Render showing saturation applied to surface ranging from 0 to 1, completely desaturated to fully saturated.


  • Value input: The shader or function nodes assigned to this setting determine the brightness of the hue. A value of 0 would result in black, while a value of 1 is the maximum brightness of the hue.
    Node network view illustrating Build HSV supplying Values to surface.
    Rendering showing values applied to surface ranging from 0 to 1, completely dark to completely bright.



A scalar is a single number. 1, 200.45, -45, -0.2 are all examples of scalar values.

A vector is a set of three scalars, normally representing X, Y and Z coordinates. It also commonly represents rotation, where the values are pitch, heading and bank.

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 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.