VEX Volume Fire
shader
This volume shader will shade volume objects as if they were flame. The density value will be used as a lookup into a color shading ramp, provided it lies within a certain range.
When attached to volume geometry, this shader will shade each point as if it were a flame. The value of the volume geometry is used both as density cut-off and as a lookup into a shading ramp. If the density is below the low value, it will be transparent. If it is over the high value and Hollow Interior is set, it will also be transparent. Otherwise, the density will be the Flame Density value (possibly multiplied by the alpha if a texture map is used)
If no texture map is specified, the low, mid, and high colors will be used as the flame color for each of the specified density values. If a texture map is specified, its full width will be stretched into the low to high value range and used. An alpha on the texture map will modulate the density accordingly.
The Shadow Density is used when shadow rays are cast through the flame, allowing for the flame to be transparent in the shadow pass.
Because the fog is sampled internally, default shadow shaders like Fast Shadow that return inside/outside will result in aliasing. If shadows do not need to cast on the fog, they can be turned off easily in this SHOP. Otherwise, one should use deep shadow maps or another method of getting soft shadows.
The Emission parameter causes the fire to add light to the ray without affecting the opacity. This allows the fire to blow out to white rather than blending into an ugly salmon color. Emission is specified in amount per unit distance sampled, so large values may be needed for small fires.
Usages in other examples
| Example name | Example for | |
|---|---|---|
| TwoColourFire |
Smoke Object dynamics node |