Bug 208828 - Remove the special DisplayList handling in CanvasRenderingContext2DBase
Summary: Remove the special DisplayList handling in CanvasRenderingContext2DBase
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Canvas (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Said Abou-Hallawa
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-03-09 13:09 PDT by Said Abou-Hallawa
Modified: 2020-03-10 10:53 PDT (History)
11 users (show)

See Also:


Attachments
Patch (6.93 KB, patch)
2020-03-09 13:10 PDT, Said Abou-Hallawa
no flags Details | Formatted Diff | Diff
Patch (9.51 KB, patch)
2020-03-09 17:24 PDT, Said Abou-Hallawa
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Said Abou-Hallawa 2020-03-09 13:09:19 PDT
Recording the drawing commands and replaying them to the backend is already implemented and should be handled by DisplayList::ImageBuffer.
Comment 1 Said Abou-Hallawa 2020-03-09 13:10:51 PDT
Created attachment 393064 [details]
Patch
Comment 2 Said Abou-Hallawa 2020-03-09 17:24:29 PDT
Created attachment 393096 [details]
Patch
Comment 3 Myles C. Maxfield 2020-03-09 22:24:04 PDT
Comment on attachment 393096 [details]
Patch

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

> Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp:2062
>      if (UNLIKELY(m_usesDisplayListDrawing)) {

We should probably go farther and delete the whole thing, LayoutTests and all.
Comment 4 Said Abou-Hallawa 2020-03-10 09:50:50 PDT
Comment on attachment 393096 [details]
Patch

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

>> Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp:2062
>>      if (UNLIKELY(m_usesDisplayListDrawing)) {
> 
> We should probably go farther and delete the whole thing, LayoutTests and all.

This DisplayList recording and replay back is used by CustomPaintCanvas, OffscreenCanvas and WebGLRenderingContextBase. A CanvasRenderingContext2DBase is created without an ImageBuffer. The drawing commands are recorded and later replayed back on the context of a temporary ImageBuffer. It will be nice if we can remove that. But at least for now I think it is okay to remove the code duplication.
Comment 5 WebKit Commit Bot 2020-03-10 10:52:12 PDT
Comment on attachment 393096 [details]
Patch

Clearing flags on attachment: 393096

Committed r258219: <https://trac.webkit.org/changeset/258219>
Comment 6 WebKit Commit Bot 2020-03-10 10:52:14 PDT
All reviewed patches have been landed.  Closing bug.
Comment 7 Radar WebKit Bug Importer 2020-03-10 10:53:14 PDT
<rdar://problem/60279998>