Commit 9572c36
committed
Add "srgb-linear" and "display-p3-linear" to PredefinedColorSpace
https://bugs.webkit.org/show_bug.cgi?id=306644
Reviewed by Devin Rousso.
Adds support for "srgb-linear" and "display-p3-linear" to PredefinedColorSpace.
Mostly plumbing, as underlying support was already there.
Also imports relevant test cases from WPT.
Tests: imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.display-p3-linear.html
imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.srgb-linear.html
imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear.html
imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear.worker.html
imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear.html
imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear.worker.html
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.display-p3-linear-expected.txt: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.display-p3-linear.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.fillText.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.fillText.shadow.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.strokeText.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.to.p3.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.to.srgb-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.to.srgb.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.toBlob.p3.canvas.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.toBlob.with.putImageData.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.toDataURL.jpeg.p3.canvas.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.toDataURL.p3.canvas.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.toDataURL.with.putImageData.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.srgb-linear-expected.txt: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/2d.color.space.srgb-linear.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/WEB_FEATURES.yml: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/wide-gamut-canvas/w3c-import.log:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear-expected.txt: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear.worker-expected.txt: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear.worker.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.display-p3-linear.worker.js: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.p3.to.p3.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.p3.to.p3.worker.js:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.p3.to.srgb-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.p3.to.srgb.html:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.p3.to.srgb.worker-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.p3.to.srgb.worker.js:
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear-expected.txt: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear.worker-expected.txt: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear.worker.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/2d.color.space.srgb-linear.worker.js: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/WEB_FEATURES.yml: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/canvas/offscreen/wide-gamut-canvas/w3c-import.log:
* Source/JavaScriptCore/inspector/protocol/Canvas.json:
* Source/WebCore/bindings/js/SerializedScriptValue.cpp:
* Source/WebCore/html/canvas/PredefinedColorSpace.cpp:
* Source/WebCore/html/canvas/PredefinedColorSpace.h:
* Source/WebCore/html/canvas/PredefinedColorSpace.idl:
* Source/WebCore/inspector/InspectorCanvas.cpp:
* Source/WebCore/platform/graphics/ColorConversion.cpp:
* Source/WebCore/platform/graphics/PlatformColorSpace.h:
* Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js:
* Source/WebInspectorUI/UserInterface/Models/Canvas.js:
* Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in:
Canonical link: https://commits.webkit.org/306563@main1 parent d5b064d commit 9572c36
File tree
46 files changed
+457
-42
lines changed- LayoutTests/imported/w3c/web-platform-tests/html/canvas
- element/wide-gamut-canvas
- offscreen/wide-gamut-canvas
- Source
- JavaScriptCore/inspector/protocol
- WebCore
- bindings/js
- html/canvas
- inspector
- platform/graphics
- WebInspectorUI
- Localizations/en.lproj
- UserInterface/Models
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
46 files changed
+457
-42
lines changedLines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
Lines changed: 51 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
26 | 27 | | |
27 | 28 | | |
28 | 29 | | |
29 | | - | |
| 30 | + | |
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
| |||
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
11 | | - | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
19 | | - | |
| 20 | + | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
| |||
25 | 26 | | |
26 | 27 | | |
27 | 28 | | |
28 | | - | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
0 commit comments