colour_hdri.tonemapping_operator_exponential#

colour_hdri.tonemapping_operator_exponential(RGB: ArrayLike, q: float = 1, k: float = 1, colourspace: RGB_Colourspace = RGB_COLOURSPACES['sRGB']) NDArrayFloat[source]#

Perform given RGB array tonemapping using the exponential method.

Parameters:
  • RGB (ArrayLike) – RGB array to perform tonemapping onto.

  • q (float) – \(q\).

  • k (float) – \(k\).

  • colourspace (RGB_Colourspace) – RGB colourspace used for internal Luminance computation.

Returns:

Tonemapped RGB array.

Return type:

numpy.ndarray

References

[BADC11b]

Examples

>>> tonemapping_operator_exponential(
...     np.array(
...         [
...             [
...                 [0.48046875, 0.35156256, 0.23632812],
...                 [1.39843753, 0.55468757, 0.39062594],
...             ],
...             [
...                 [4.40625388, 2.15625895, 1.34375372],
...                 [6.59375023, 3.43751395, 2.21875829],
...             ],
...         ]
...     ),
...     1.0,
...     25,
... )  
array([[[ 0.0148082...,  0.0108353...,  0.0072837...],
        [ 0.0428669...,  0.0170031...,  0.0119740...]],

       [[ 0.1312736...,  0.0642404...,  0.0400338...],
        [ 0.1921684...,  0.1001830...,  0.0646635...]]])