Sub topic 3
Colour spaces and gamut: what each device can reproduce
Assume you know basic digital-image terms and can read simple arithmetic. This chapter focuses on how colour models behave on real devices.
Colour spaces and gamut
A colour space defines how numerical colour values map to visible colours. A gamut is the range of colours that a device or colour space can reproduce.
A monitor, phone, inkjet printer, and commercial press each have different gamuts. A bright screen green may have no exact equivalent in CMYK ink. Conversion must replace it with a printable colour, so the result may look duller.
sRGB and gamma
sRGB is a common RGB colour space for websites and general-purpose images. Its channel values use non-linear encoding, often called gamma encoding. The value 128 is halfway between 0 and 255 numerically, but it represents about 21.6% of full linear light, not 50%.
This encoding gives useful precision across the range that people can see. Arithmetic such as blending or calculating light intensity should use linear-light values when accuracy matters.
Converting RGB to CMYK
CMYK models subtractive mixing. Cyan, magenta, and yellow inks absorb parts of white light. K represents black ink.
A simple conversion treats RGB and CMYK as ideal, device-independent values:
def rgb_to_cmyk_naive(r, g, b):
r, g, b = r / 255, g / 255, b / 255
k = 1 - max(r, g, b)
if k == 1:
return 0.0, 0.0, 0.0, 1.0
c = (1 - r - k) / (1 - k)
m = (1 - g - k) / (1 - k)
y = (1 - b - k) / (1 - k)
return c, m, y, kThis formula ignores the ink, paper, press, and source RGB colour space. It is useful for learning, but it cannot reliably predict printed appearance.
ICC profiles and rendering intents
An ICC profile describes how a particular colour space or device produces colour. Colour-managed software uses profiles to convert between spaces.
A rendering intent chooses how to handle out-of-gamut colours:
- Relative colorimetric preserves in-gamut colours and clips others.
- Perceptual compresses the whole range to preserve relationships.
- Absolute colorimetric also considers the paper or media white.
- Saturation prioritises vividness over exact colour accuracy.
Practical workflow
Use sRGB for most web and app deliverables unless a platform specifies another space. Embed the profile when exporting. For print, ask the printer for its required CMYK profile, convert with colour-managed software, and inspect a proof. Do not assume that changing an RGB file to “CMYK” alone predicts the press result.
Exercise
Why can a vivid sRGB colour become dull after conversion to CMYK?
Show answer
The colour may be outside the printer's CMYK gamut, so the conversion must remap it to a reproducible colour.