TG Fog2 Ramp

TG Fog2 Ramp Gradient producing a particularly yucky looking fog that I wouldn't want to be in, with colour that varies with distance as well as fog strength.

TG Fog2 Ramp Gradient allows you to have fog or depth cue which varies in colour as well as in intensity (TG Fog2 Ramp Gradient was also used in this landscape image here)

What It Does

This shader is a Ramp and Gradient driven version of the free Fog2 shader. As an object gets further from the camera, the surface tends toward the fog colour, including the diffuse, specular and reflective channels. The Gradient means that as well as fog depth or strength varying with distance, the fog colour can vary independently with distance too.

Quick Features and Suggested Uses

Using this shader in place of the inbuilt post-process Fog or Depth Cue in trueSpace has several advantages

1) You can control the way the fog / depth cue effect “thickens” with distance, through use of the Ramp, providing a great deal of flexibility (including adding some noise, if you wanted).

2) As well as controlling the “thickness” of the fog / depth cue effect, you can also vary the colour with distance, through use of the Gradient. This allows much more interesting fog / depth cue effects (eg fading with distance to a pale bluish colour, then fading to white with increasing distance, for a haze effect). With the inbuilt tS shaders, the effect only fades from no colour to background colour.

3) The shader enables you to use Simple Volumetrics on the scene in conjunction with this fog / depth cue effect (not possible in tS, as you must select Fog or Depth Cue, in place of Simple Volumetrics), or you can use Advanced Volumetrics without using the Attenuation parameter to create the fog / depth cue effect (freeing you to set the Advanced Volumetrics any way you like).

4) Since it is applied on a per object (or per material) basis, you can control the fog / depth cue effect independently for each, either to avoid the necessity of trying to scale everything to get the desired effects on foreground and background objects, or for unusual effects. Try adding a haze onto a tall-ish cube to give an impression of height, for instance, even with a short cube!

 

Please note that this shader will need to be used for every material that is to be affected by the fog / depth cue effect.

TG Fog2 Ramp Intro

TG Fog2 Ramp Parameters

TG Pack 3 Index