Skip to content

Commit 80b0cff

Browse files
committed
[css-color-4] add gamut volume comparison
1 parent 806dd84 commit 80b0cff

File tree

3 files changed

+42
-1
lines changed

3 files changed

+42
-1
lines changed

css-color-4/Overview.bs

+34-1
Original file line numberDiff line numberDiff line change
@@ -147,10 +147,43 @@ Value Definitions</h3>
147147

148148
Real physical devices cannot yet produce every possible color that the human eye can see.
149149
The range of colors that a given device can produce is termed the <dfn export>gamut</dfn>
150-
<em>not to be confused with gamma</em>.
150+
<em>(not to be confused with gamma)</em>.
151151
Devices with a limited gamut cannot produce very saturated colors,
152152
like those found in a rainbow.
153153

154+
The gamuts of different colorspaces may be compared by looking at the volume (in cubic LAB units) of colors that can be expressed. The following table examines the <a>predefined</a> colorspaces available in CSS.
155+
156+
<table class=gamuts>
157+
<tr>
158+
<th>Colorspace</th>
159+
<th>Volume (million Lab units)</th>
160+
</tr>
161+
<tr>
162+
<td>sRGB</td>
163+
<td>0.820</td>
164+
</tr>
165+
<tr>
166+
<td>display-p3</td>
167+
<td>1.233</td>
168+
</tr>
169+
<tr>
170+
<td>a98-rgb</td>
171+
<td>1.310</td>
172+
</tr>
173+
<tr>
174+
<td>prophoto-rgb</td>
175+
<td>2.896</td>
176+
</tr>
177+
<tr>
178+
<td>rec2020</td>
179+
<td>2.042</td>
180+
</tr>
181+
<tr>
182+
<td>lab</td>
183+
<td>6.578</td>
184+
</tr>
185+
</table>
186+
154187
<h2 id="the-color-property">
155188
Foreground Color: the 'color' property</h2>
156189

css-color-4/style.css

+4
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,7 @@
1515
border-radius: 2px;
1616
transition: .4s;
1717
}
18+
19+
table.gamuts tr:hover {
20+
background: papayawhip;
21+
}

css-color-5/style.css

+4
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,7 @@
1515
border-radius: 2px;
1616
transition: .4s;
1717
}
18+
19+
table.gamuts tr:hover {
20+
background: papayawhip;
21+
}

0 commit comments

Comments
 (0)