Bug 217506 - [Cocoa] [GPU Process] Perform image decoding of color fonts in the Web Process
Summary: [Cocoa] [GPU Process] Perform image decoding of color fonts in the Web Process
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Text (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Myles C. Maxfield
URL:
Keywords: InRadar
Depends on: 217539 217541 217749
Blocks:
  Show dependency treegraph
 
Reported: 2020-10-09 00:10 PDT by Myles C. Maxfield
Modified: 2020-10-16 12:02 PDT (History)
8 users (show)

See Also:


Attachments
WIP (45.27 KB, patch)
2020-10-09 00:11 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
WIP (29.61 KB, patch)
2020-10-09 20:01 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
WIP (29.62 KB, patch)
2020-10-09 20:02 PDT, Myles C. Maxfield
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
WIP (29.69 KB, patch)
2020-10-09 20:20 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
WIP (35.31 KB, patch)
2020-10-13 00:18 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
Almost ready (36.35 KB, patch)
2020-10-13 18:53 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
WIP (49.21 KB, patch)
2020-10-14 00:35 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
Needs tests (36.60 KB, patch)
2020-10-15 18:47 PDT, Myles C. Maxfield
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Needs tests (36.61 KB, patch)
2020-10-15 18:50 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
Ahem with sbix table (39.04 KB, application/x-font-ttf)
2020-10-15 21:15 PDT, Myles C. Maxfield
no flags Details
Needs COLR test (77.98 KB, patch)
2020-10-15 22:09 PDT, Myles C. Maxfield
no flags Details | Formatted Diff | Diff
Patch (86.00 KB, patch)
2020-10-16 01:00 PDT, Myles C. Maxfield
ews-feeder: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Myles C. Maxfield 2020-10-09 00:10:17 PDT
[Cocoa] [GPU Process] Perform image decoding of color fonts in the Web Process
Comment 1 Myles C. Maxfield 2020-10-09 00:11:26 PDT
Created attachment 410919 [details]
WIP
Comment 2 Myles C. Maxfield 2020-10-09 00:11:28 PDT
<rdar://problem/69768186>
Comment 3 Myles C. Maxfield 2020-10-09 00:13:11 PDT
I need to:

1. Split this patch up into 3 pieces
2. Work out the details (see comments in the WIP patch)
3. Add tests
Comment 4 Simon Fraser (smfr) 2020-10-09 09:31:13 PDT
Comment on attachment 410919 [details]
WIP

View in context: https://bugs.webkit.org/attachment.cgi?id=410919&action=review

Are we going to record all glyph drawing? Currently we don't have a way to measure perf impact (no motionmark test draws text into canvas); should we wait to land this until we can measure its perf impact?

> Source/WebCore/platform/graphics/displaylists/DisplayListDrawGlyphsRecorder.h:50
> +    DrawGlyphsRecorder(Recorder&);

explicit
Comment 5 Myles C. Maxfield 2020-10-09 20:01:17 PDT
Created attachment 410998 [details]
WIP
Comment 6 Myles C. Maxfield 2020-10-09 20:02:32 PDT
Created attachment 410999 [details]
WIP
Comment 7 Myles C. Maxfield 2020-10-09 20:20:38 PDT
Created attachment 411002 [details]
WIP
Comment 8 Myles C. Maxfield 2020-10-09 23:39:33 PDT
After playing around with this for a little while, the only canvas tests I could write that were broken by this patch are:

1. The placement of images and their shadows
2. Shadows of COLR glyphs
Comment 9 Myles C. Maxfield 2020-10-13 00:18:17 PDT
Created attachment 411200 [details]
WIP
Comment 10 Myles C. Maxfield 2020-10-13 18:53:20 PDT
Created attachment 411291 [details]
Almost ready
Comment 11 Myles C. Maxfield 2020-10-14 00:35:50 PDT
Created attachment 411305 [details]
WIP
Comment 12 Myles C. Maxfield 2020-10-15 18:47:36 PDT
Created attachment 411517 [details]
Needs tests
Comment 13 Myles C. Maxfield 2020-10-15 18:50:14 PDT
Created attachment 411520 [details]
Needs tests
Comment 14 Myles C. Maxfield 2020-10-15 21:15:38 PDT
Created attachment 411531 [details]
Ahem with sbix table
Comment 15 Myles C. Maxfield 2020-10-15 22:09:38 PDT
Created attachment 411534 [details]
Needs COLR test
Comment 16 Myles C. Maxfield 2020-10-16 01:00:02 PDT
Created attachment 411542 [details]
Patch
Comment 17 Myles C. Maxfield 2020-10-16 01:02:30 PDT
This is almost ready.

Two things are remaining:
1. Performance testing
2. sbix images seem to be horizontally flipped
Comment 18 Myles C. Maxfield 2020-10-16 01:04:26 PDT
3. There are a few FIXMEs
Comment 19 Myles C. Maxfield 2020-10-16 01:07:11 PDT
Comment on attachment 411542 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=411542&action=review

> Source/WebCore/platform/graphics/displaylists/DisplayListDrawGlyphsRecorderCoreText.cpp:133
> +    updateCTM(m_originalCTM);

There might be more to do here.
Comment 20 Myles C. Maxfield 2020-10-16 12:02:22 PDT
We probably should never set the CTM. We probably should always append a modification instead. Just in case, to be defensive.