Documentation
    Preparing search index...

    Function effectShaderSource

    • The WGSL module for one effect kind โ€” a pure function of the kind, so two calls produce byte-identical source and the pipeline cache can key on the descriptor (ยง33's rule, as every generated module in this package states it).

      • "copy" assigns the sampled texel to the output with no arithmetic between โ€” the bit-exact blit CopyEffect promises, by construction.
      • "grade" runs ColorGradeEffect's three operations in its documented order on straight linear-light RGB, alpha untouched, nothing clamped (the rgba8 destination saturates on write; a future float target must not be silently clamped into agreeing with it).
      • "output-transform" encodes linear-light RGB as sRGB โ€” the piecewise IEC 61966-2-1 curve @fourjs/math's linearToSrgb computes on the CPU, odd-extended below zero by taking the magnitude and restoring the sign so a negative texel never reaches pow (undefined for a negative base). Alpha is a coverage fraction, not a light quantity, and is not encoded.

      Parameters

      Returns string