colour.chromatically_adapted_primaries#

colour.chromatically_adapted_primaries(primaries: ArrayLike, whitepoint_t: ArrayLike, whitepoint_r: ArrayLike, chromatic_adaptation_transform: Literal['Bianco 2010', 'Bianco PC 2010', 'Bradford', 'CAT02 Brill 2008', 'CAT02', 'CAT16', 'CMCCAT2000', 'CMCCAT97', 'Fairchild', 'Sharp', 'Von Kries', 'XYZ Scaling'] | str = 'CAT02') NDArrayFloat[source]#

Chromatically adapt given primaries \(xy\) chromaticity coordinates from test whitepoint_t to reference whitepoint_r.

Parameters:
  • primaries (ArrayLike) – Primaries \(xy\) chromaticity coordinates.

  • whitepoint_t (ArrayLike) – Test illuminant / whitepoint \(xy\) chromaticity coordinates.

  • whitepoint_r (ArrayLike) – Reference illuminant / whitepoint \(xy\) chromaticity coordinates.

  • chromatic_adaptation_transform (Literal['Bianco 2010', 'Bianco PC 2010', 'Bradford', 'CAT02 Brill 2008', 'CAT02', 'CAT16', 'CMCCAT2000', 'CMCCAT97', 'Fairchild', 'Sharp', 'Von Kries', 'XYZ Scaling'] | str) – Chromatic adaptation transform.

Returns:

Chromatically adapted primaries \(xy\) chromaticity coordinates.

Return type:

numpy.ndarray

Examples

>>> p = np.array([0.64, 0.33, 0.30, 0.60, 0.15, 0.06])
>>> w_t = np.array([0.31270, 0.32900])
>>> w_r = np.array([0.34570, 0.35850])
>>> chromatic_adaptation_transform = "Bradford"
>>> chromatically_adapted_primaries(p, w_t, w_r, chromatic_adaptation_transform)
... 
array([[ 0.6484414...,  0.3308533...],
       [ 0.3211951...,  0.5978443...],
       [ 0.1558932...,  0.0660492...]])