Defines a light flare effect usable by scene lights.
- Inherit:
SimDataBlock
LightFlareData is a datablock which defines a type of flare effect. This may then be referenced by other classes which support the rendering of a flare: Sun, ScatterSky, LightBase.
A flare contains one or more elements defined in the element* named fields of LightFlareData, with a maximum of ten elements. Each element is rendered as a 2D sprite in screenspace.
Example:
// example from Full Template, core/art/datablocks/lights.cs
datablock LightFlareData( LightFlareExample0 )
{
overallScale = 2.0;
flareEnabled = true;
renderReflectPass = true;
flareTexture = "./../special/lensFlareSheet1";
occlusionRadius = 0.25;
elementRect[0] = "0 512 512 512";
elementDist[0] = 0.0;
elementScale[0] = 0.5;
elementTint[0] = "1.0 1.0 1.0";
elementRotate[0] = false;
elementUseLightColor[0] = false;
elementRect[1] = "512 0 512 512";
elementDist[1] = 0.0;
elementScale[1] = 2.0;
elementTint[1] = "0.5 0.5 0.5";
elementRotate[1] = false;
elementUseLightColor[1] = false;
};
The elementDist field defines where along the flare's beam the element appears. A distance of 0.0 is directly over the light source, a distance of 1.0 is at the screen center, and a distance of 2.0 is at the position of the light source mirrored across the screen center.