@@ -931,8 +931,9 @@ Representing Colors: the <<color>> type</h2>
931931 which allows specifying colors in a variety of color spaces
932932 including
933933 [[#predefined-sRGB|sRGB]] ,
934- [[#predefined-sRGB-linear|Linear-light sRGB]] ,
934+ [[#predefined-sRGB-linear|Linear-Light sRGB]] ,
935935 [[#predefined-display-p3|Display P3]] ,
936+ [[#predefined-display-p3-linear|Linear-Light Display P3]] ,
936937 [[#predefined-a98-rgb|A98 RGB]] ,
937938 [[#predefined-prophoto-rgb|ProPhoto RGB]] ,
938939 [[#predefined-rec2020|ITU-R BT.2020-2]] ,
@@ -3792,7 +3793,7 @@ Specifying Predefined Colors: the ''color()'' function</h3>
37923793 <dfn>color()</dfn> = color( <<colorspace-params>> [ / [ <<alpha-value>> | none ] ]? )
37933794 <dfn><colorspace-params></dfn> = [ <<predefined-rgb-params>> | <<xyz-params>> ]
37943795 <dfn><predefined-rgb-params></dfn> = <<predefined-rgb>> [ <<number>> | <<percentage>> | none ]{3}
3795- <dfn><predefined-rgb></dfn> = <l>''srgb''</l> | <l>''srgb-linear''</l> | <l>''display-p3''</l> | <l>''a98-rgb''</l> | <l>''prophoto-rgb''</l> | <l>''rec2020''</l>
3796+ <dfn><predefined-rgb></dfn> = <l>''srgb''</l> | <l>''srgb-linear''</l> | <l>''display-p3''</l> | <li>''display-p3-linear''</li> | < l>''a98-rgb''</l> | <l>''prophoto-rgb''</l> | <l>''rec2020''</l>
37963797 <dfn><xyz-params></dfn> = <<xyz-space>> [ <<number>> | <<percentage>> | none ]{3}
37973798 <dfn><xyz-space></dfn> = <l>''xyz''</l> | <l>''xyz-d50''</l> | <l>''xyz-d65''</l>
37983799 </pre>
@@ -3977,7 +3978,7 @@ The Predefined sRGB Color Space: the ''sRGB'' keyword</h3>
39773978 </wpt>
39783979
39793980<h3 id="predefined-sRGB-linear">
3980- The Predefined Linear-light sRGB Color Space: the ''srgb-linear'' keyword</h3>
3981+ The Predefined Linear-Light sRGB Color Space: the ''srgb-linear'' keyword</h3>
39813982
39823983
39833984 The <dfn id='sRGB-linear-space' export>sRGB-linear</dfn> predefined color space
@@ -4119,6 +4120,56 @@ The Predefined Display P3 Color Space: the ''display-p3'' keyword</h3>
41194120 2d.color.space.p3.toDataURL.with.putImageData.html
41204121 </wpt>
41214122
4123+ <h3 id="predefined-display-p3-linear">
4124+ The Predefined Linear-Light Display P3 Color Space: the ''display-p3-linear'' keyword</h3>
4125+
4126+
4127+ The <dfn id='display-p3-linear-space' export>display-p3-linear</dfn> predefined color space
4128+ is the same as ''display-p3''
4129+ <em> except</em> that the transfer function
4130+ is linear-light (there is no gamma-encoding).
4131+
4132+ It has the following characteristics:
4133+
4134+ <table id="prr-color-display-p3-linear">
4135+ <thead><td></td><td> x</td><td> y</td></thead>
4136+ <tr><th> Red chromaticity</th><td> 0.680</td><td> 0.320</td></tr>
4137+ <tr><th> Green chromaticity</th><td> 0.265</td><td> 0.690</td></tr>
4138+ <tr><th> Blue chromaticity</th><td> 0.150</td><td> 0.060</td></tr>
4139+ <tr><th> White chromaticity</th> <td colspan="2"> [=D65=] </td></tr>
4140+ <tr><th> Transfer function</th><td colspan="2"> unity, see below </td></tr>
4141+ <tr><th> White luminance</th><td colspan="2"> 80.0 cd/m<sup> 2</sup></td></tr>
4142+ <tr><th> Black luminance</th><td colspan="2"> 0.80 cd/m<sup> 2</sup></td></tr>
4143+ <tr><th> Image state</th><td colspan="2"> display-referred</td></tr>
4144+ <tr>
4145+ <th> Percentages</th>
4146+ <td colspan="2"> Allowed for R, G and B</td>
4147+ </tr>
4148+ <tr>
4149+ <th> Percent reference range </th>
4150+ <td> for R,G,B: 0% = 0.0, 100% = 1.0</td>
4151+ </tr>
4152+ </table>
4153+
4154+ <pre class="lang-javascript">
4155+ cl = c;
4156+ </pre>
4157+
4158+ c is the red, green or blue component.
4159+ cl is the corresponding linear-light component, which is identical.
4160+
4161+ To avoid banding artifacts, a
4162+ <a href="#predefined-precision-table">higher precision is required</a>
4163+ for ''display-p3-linear'' than for ''display-p3'' .
4164+
4165+ <div class="example" id="display-p3-linear-swatches">
4166+ For example, these are the same color
4167+ <pre class="lang-css">
4168+ <span class="swatch" style="--color: rgb(64.55% 2.065% 26.03%)"></span> color(display-p3 0.591 0.123 0.264)
4169+ <span class="swatch" style="--color: rgb(64.55% 2.065% 26.03%)"></span> color(display-p3-linear 0.3081 0.014 0.0567)
4170+ </pre>
4171+ </div>
4172+
41224173
41234174<h3 id="predefined-a98-rgb">
41244175The Predefined A98 RGB Color Space: the ''a98-rgb'' keyword</h3>
@@ -4714,13 +4765,13 @@ Color Space for Interpolation</h3>
47144765 Thus, different color spaces may be more appropriate for each interpolation use case.
47154766
47164767 * In some cases, the result of physically mixing two colored lights is desired.
4717- In that case, the CIE XYZ or srgb-linear color space is appropriate, because they are linear in light intensity.
4768+ In that case, the CIE '' XYZ'' , ''display-p3-linear'' or '' srgb-linear'' color spaces are appropriate, because they are linear in light intensity.
47184769 * If colors need to be evenly spaced perceptually (such as in a gradient),
4719- the Oklab color space (and the older Lab), are designed to be perceptually uniform.
4770+ the '' Oklab'' color space (and the older '' Lab'' ), are designed to be perceptually uniform.
47204771 * If avoiding graying out in color mixing is desired, i.e. maximizing chroma throughout the transition,
4721- OkLCh (and the older LCH) work well for that.
4772+ '' OkLCh'' (and the older '' LCH'' ) work well for that.
47224773 * Lastly, compatibility with legacy Web content may be the most important consideration.
4723- The sRGB color space, which is neither linear-light nor perceptually uniform, is the choice here,
4774+ The '' sRGB'' color space, which is neither linear-light nor perceptually uniform, is the choice here,
47244775 even though it produces poorer results (overly dark or greyish mixes).
47254776
47264777 These features are collectively termed the <dfn export>host syntax</dfn> .
@@ -4744,7 +4795,7 @@ Color Space for Interpolation</h3>
47444795
47454796 <pre class='prod'>
47464797 <dfn export><color-space></dfn> = <rectangular-color-space> | <polar-color-space>
4747- <dfn export><rectangular-color-space></dfn> = <l>''srgb''</l> | <l>''srgb-linear''</l> | <l>''display-p3''</l> | <l>''a98-rgb''</l> | <l>''prophoto-rgb''</l> | <l>''rec2020''</l> | <l>''lab''</l> | <l>''oklab''</l> | <<xyz-space>>
4798+ <dfn export><rectangular-color-space></dfn> = <l>''srgb''</l> | <l>''srgb-linear''</l> | <l>''display-p3''</l> | <l>''display-p3-linear''</l> | <l>'' a98-rgb''</l> | <l>''prophoto-rgb''</l> | <l>''rec2020''</l> | <l>''lab''</l> | <l>''oklab''</l> | <<xyz-space>>
47484799 <dfn export><polar-color-space></dfn> = <l>''hsl''</l> | <l>''hwb''</l> | <l>''lch''</l> | <l>''oklch''</l>
47494800 <dfn export><hue-interpolation-method></dfn> = [ shorter | longer | increasing | decreasing ] hue
47504801 <dfn export id="color-interpolation-method"><color-interpolation-method></dfn> = in [ <<rectangular-color-space>> | <<polar-color-space>> <<hue-interpolation-method>> ? ]
@@ -6705,6 +6756,10 @@ Serializing values of the ''color()'' function</h3>
67056756 <td> ''display-p3'' </td>
67066757 <td> 10</td>
67076758 </tr>
6759+ <tr>
6760+ <td> ''display-p3-linear'' </td>
6761+ <td> 12</td>
6762+ </tr>
67086763 <tr>
67096764 <td> ''a98-rgb'' </td>
67106765 <td> 10</td>
0 commit comments