colour.constant_spd

colour.constant_spd(k, shape=SpectralShape(360, 780, 1), dtype=<type 'numpy.float64'>)[source]

Returns a spectral power distribution of given spectral shape filled with constant \(k\) values.

Parameters:
  • k (numeric) – Constant \(k\) to fill the spectral power distribution with.
  • shape (SpectralShape, optional) – Spectral shape used to create the spectral power distribution.
  • dtype (type) – Data type used for the spectral power distribution.
Returns:

Constant \(k\) to filled spectral power distribution.

Return type:

SpectralPowerDistribution

Notes

Examples

>>> spd = constant_spd(100)
>>> spd.shape
SpectralShape(360.0, 780.0, 1.0)
>>> spd[400]
100.0