Color Science - ISET/isetcam GitHub Wiki
Color is computed throughout the pipeline, not one stage of it
Color science does not live in a single ISETCam structure. It connects scene illuminants, sensor color filters, image-processing color balance, display primaries, and image-quality metrics — see the Core Pipeline pages for each of those. This page collects the shared colorimetric building blocks those pages all rely on.
Illuminants
Scene illumination (see Scene Radiance) is created with:
bb = blackbody(400:10:700, 5500, 'energy'); % 5500 K blackbody radiator
ill = illuminantCreate('d65', 400:10:700); % Named illuminant, e.g. daylight
d = daylight(400:10:700, 6500); % CIE daylight series at a given CCT
t_colorEnergyQuanta (see
Tutorials) covers
converting between energy and photon-quanta units for these spectra.
Color matching and chromaticity
ieXYZFromPhotons converts spectral radiance or irradiance (in photons)
into CIE XYZ tristimulus values, using the CIE color matching functions.
From XYZ, xyy2xyz and xyz2uv compute the chromaticity coordinates
plotted in a standard CIE chromaticity diagram. t_colorMatching and
t_colorChromaticity (see
Tutorials) work
through both.
Colorimetric transforms
color/transforms/ implements the standard conversions between the color
spaces ISETCam uses at different pipeline stages:
| From -> To | Function |
|---|---|
| XYZ <-> CIELAB | ieXYZ2LAB, ieLAB2XYZ |
| XYZ <-> LMS (cone) | xyz2lms, lms2xyz |
| XYZ <-> sRGB | xyz2srgb, srgb2xyz |
| linear RGB <-> sRGB | lrgb2srgb, srgb2lrgb |
| LMS -> sRGB | lms2srgb |
| xyY <-> XYZ | xyy2xyz |
| sRGB -> correlated color temperature | srgb2colortemp |
colorTransformMatrix / colorTransformMatrixCreate build the linear
transforms (for example, sensor-to-XYZ) used by the image processor's
sensor conversion methods.
Recommended tutorials and examples
- Image processing, color, metrics, and displays —
t_colorMatching,t_colorChromaticity, andt_colorEnergyQuanta. - Examples —
examples/color/has further scripts, includings_srgbGamut(display gamut) ands_colorIlluminantTransforms(blackbody illuminant correction).
Related FISE concepts
The online Foundations of Image Systems Engineering (FISE) develops color matching, chromaticity, and color spaces in more depth as conceptual background.
Boundaries: human color vision
The functions above describe colorimetry — how spectra map to standard color spaces such as XYZ and CIELAB — not the biological mechanisms of human color vision (cone spectral sensitivities, opponent processes, color appearance). For detailed modeling of the human visual system, see ISETBio.