Whether gamma == 1.0 (with ±1e-4 epsilon for float-equality
safety). When true, the fragment shader can skip its per-fragment
pow(color, 1.0 / gamma) calls — pow(x, 1) == x — by compiling in
the LUXAR_GAMMA_ONE define (GLSL) / gammaOne config flag (TSL).
Shared across all four geometry types (Point / Line / GSplat / Mesh)
× both backends so the fast-path threshold is identical everywhere.
DELIBERATELY no hysteresis (2026-07 debt-remediation decision):
crossing the boundary flips the LUXAR_GAMMA_ONE define and costs one
shader recompile per crossing. A hysteresis band wide enough to
matter would keep the pow()-skipping fast path engaged at gamma
values measurably off 1.0 — a silent visual error on scientific
data — while the band below is already ±1e-4 (effectively "exactly
1.0"), so per-frame toggle thrash would require a slider oscillating
inside a 0.0002-wide window. Two bounded recompiles per deliberate
crossing is the correct trade.
Whether
gamma == 1.0(with ±1e-4 epsilon for float-equality safety). When true, the fragment shader can skip its per-fragmentpow(color, 1.0 / gamma)calls —pow(x, 1) == x— by compiling in theLUXAR_GAMMA_ONEdefine (GLSL) /gammaOneconfig flag (TSL).Shared across all four geometry types (Point / Line / GSplat / Mesh) × both backends so the fast-path threshold is identical everywhere.
DELIBERATELY no hysteresis (2026-07 debt-remediation decision): crossing the boundary flips the LUXAR_GAMMA_ONE define and costs one shader recompile per crossing. A hysteresis band wide enough to matter would keep the pow()-skipping fast path engaged at gamma values measurably off 1.0 — a silent visual error on scientific data — while the band below is already ±1e-4 (effectively "exactly 1.0"), so per-frame toggle thrash would require a slider oscillating inside a 0.0002-wide window. Two bounded recompiles per deliberate crossing is the correct trade.