Re: [csswg-drafts] [css-color-4] statement about range of 'a' parameter in lab() appears incorrect (#12208)

If I had to guess, that 160 statement is referring to the Rec. 2020 range, but that value is rounded. If so, then maybe stating that it is "approximately" 160 would make clear that the value is not an exact limit.

If we are using the sRGB, Display P3, or the Adobe RGB (1998) gamut as a reference, this statement is correct. While you are in gamut, you never exceed 160.

```
---- lab range in srgb ----
l: [0.0, 100.0]
a: [-79.271, 93.54]
b: [-112.03, 93.394]

---- lab range in display-p3 ----
l: [0.0, 100.0]
a: [-106.539, 105.77]
b: [-115.586, 122.034]

---- lab range in a98-rgb ----
l: [0.0, 100.0]
a: [-129.084, 101.297]
b: [-113.61, 103.679]
```

If we are using the Rec 2020 gamut, this statement is not precisely correct, but close.  Though I don't know if there are even any displays that can show this entire range. If you round that value, then 160 makes sense.

```
---- lab range in rec2020 ----
l: [0.0, 100.0]
a: [-160.697, 125.889]
b: [-126.243, 132.125]
```

If we are talking about ProPhoto, then you will definitely exceed 160, but the ProPhoto gamut exceeds even the visible spectrum, the limits of the human eye. I don't think that the 160 statement is meant to cover the ProPhoto gamut. I also doubt there would ever be a monitor developed to cover this range, as it would be impractical, since no human could see all of those colors. I think this range is purposefully not considered in the 160 statement.

```
l: [0.0, 100.0]
a: [-186.699, 145.196]
b: [-172.28, 172.408]
```

So this seems to only refer to displayable SDR gamuts, not HDR gamuts, which makes sense as there is a separate HDR color spec.


-- 
GitHub Notification of comment by facelessuser
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12208#issuecomment-2888418614 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Saturday, 17 May 2025 14:11:20 UTC