SoftwareLighting namespace
Functions
- auto Distance(float d2) -> float
- Reciprocal square root estimate of the platform, where it has one worth using.
- auto ClampFalloff(float t) -> float
- Clamps a falloff parameter into [0, 1].
- auto FalloffStrength(float dist, float invDenom) -> float
- The falloff of
LightingFs.incat distancedist(in units of the far radius), see SplatLight(). -
template<bool Coreless>void SplatLightRows(float* lightmap, std::
int32_t lmW, std:: int32_t lmH, float cx, float cy, float rLm, float radiusNearNorm, float intensity, float brightness) - The row loop of SplatLight(), for a light with a flat core or (if
Coreless) without one. - auto RowHalfWidth(float v) -> float
- Returns for the half-width of a light's row, a positive value.
-
void SplatLight(float* lightmap,
std::
int32_t lmW, std:: int32_t lmH, float cx, float cy, float rLm, float radiusNearNorm, float intensity, float brightness) - Adds one light to a two-channel (intensity, brightness) float lightmap.
-
void SplatRing(float* lightmap,
std::
int32_t lmW, std:: int32_t lmH, float cx, float cy, float ringLm, float rLm, float radiusNearNorm, float intensity, float brightness, std:: int32_t* litSpans) - Adds one ring light to a two-channel (intensity, brightness) float lightmap.