Transform linear pixel values using a custom function.
The given function is evaluated on linear pixel values, that is after raw pixels have been translated to normalized pixel values (see Image.Range) and after gamma correction has been applied (see Gamma). The expression may use all members of the default Tinman script. The following arguments are available to the function expression:
The input pixel value (raw).
The input pixel value (linear) in the range [0..1].
A, B, C, D, E, F
Coefficients that can be used to transform between raw and linear pixel values:
lin = pow(raw * A + B, C) raw = pow(lin, D) * E + F D = 1 / C E = 1 / A F = -B / A
rawis the raw pixel value that is actually stored in the source image (e.g. [0..255] for 8-bit images) and
linis the linear pixel value that is stored in the image scanline buffer.
Brepresent the transformation from raw pixel values to normalized pixel values (see Image.Range);
Cis the exponent that best approximates the performed gamma correction (see Gamma).
The pixel channel the function shall be applied to. If Channel.Void, no transformation will be performed.