Gamut membership
gamutCheck whether a CSS color or source-space values fit inside sRGB, Display P3, or Rec. 2020, returning matches or null if outside all.
Instructions
Which standard display gamuts hold a color — sRGB ⊂ Display P3 ⊂ Rec. 2020, each tested in its own RGB box straight from the source space, the same ladder as the color-space.io gamut pill. smallest is the tightest one; null = beyond Rec. 2020. Membership only: nothing is gamut-mapped.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | No | source space id, e.g. 'rgb', 'oklch', 'lab', 'slog3', 'rec709' (the 'spaces' tool lists all 221) | |
| color | No | a CSS color instead of `from` + `values`: '#ff8000', 'rebeccapurple', 'oklch(0.7 0.1 50)', 'lab(54% 80 67)', 'color(display-p3 1 0.5 0)' | |
| values | No | one color in the source space |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| gamuts | Yes | ||
| smallest | Yes |