colour.models.log_encoding_CanonLog2#

colour.models.log_encoding_CanonLog2(x: FloatingOrArrayLike, bit_depth: int = 10, out_normalised_code_value: bool = True, in_reflection: bool = True) FloatingOrNDArray[source]#

Define the Canon Log 2 log encoding curve / opto-electronic transfer function.

Parameters
  • x (FloatingOrArrayLike) – Linear data \(x\).

  • bit_depth (int) – Bit depth used for conversion.

  • out_normalised_code_value (bool) – Whether the Canon Log 2 non-linear data is encoded as normalised code values.

  • in_reflection (bool) – Whether the light level \(x\) to a camera is reflection.

Returns

Canon Log 2 non-linear data.

Return type

numpy.floating or numpy.ndarray

Notes

Domain

Scale - Reference

Scale - 1

x

[0, 1]

[0, 1]

Range

Scale - Reference

Scale - 1

clog2

[0, 1]

[0, 1]

References

[Canon16]

Examples

>>> log_encoding_CanonLog2(0.18) * 100  
39.8254694...