colour_hdri.camera_space_to_sRGB#

colour_hdri.camera_space_to_sRGB(RGB: ArrayLike, M_XYZ_to_camera_space: ArrayLike) NDArrayFloat[source]#

Convert given RGB array from camera space to sRGB colourspace.

Parameters:
  • RGB (ArrayLike) – Camera space RGB colourspace array.

  • M_XYZ_to_camera_space (ArrayLike) – Matrix converting from CIE XYZ tristimulus values to camera space.

Returns:

sRGB colourspace array.

Return type:

numpy.ndarray

Examples

>>> RGB = np.array([0.80660, 0.81638, 0.65885])
>>> M_XYZ_to_camera_space = np.array(
...     [
...         [0.47160000, 0.06030000, -0.08300000],
...         [-0.77980000, 1.54740000, 0.24800000],
...         [-0.14960000, 0.19370000, 0.66510000],
...     ]
... )
>>> camera_space_to_sRGB(RGB, M_XYZ_to_camera_space)  
array([ 0.7564350...,  0.8683155...,  0.6044706...])