Bug 52582 - WebView should paint directly into a GraphicsLayer when in accelerated compositing mode
Summary: WebView should paint directly into a GraphicsLayer when in accelerated compos...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Other OS X 10.5
: P2 Normal
Assignee: Adam Roben (:aroben)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-17 08:37 PST by Adam Roben (:aroben)
Modified: 2011-01-17 17:52 PST (History)
2 users (show)

See Also:


Attachments
Paint directly into a GraphicsLayer when using accelerated compositing (25.61 KB, patch)
2011-01-17 08:42 PST, Adam Roben (:aroben)
simon.fraser: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Roben (:aroben) 2011-01-17 08:37:49 PST
WebView should paint directly into a GraphicsLayer when in accelerated compositing mode
Comment 1 Adam Roben (:aroben) 2011-01-17 08:42:54 PST
Created attachment 79179 [details]
Paint directly into a GraphicsLayer when using accelerated compositing
Comment 2 Simon Fraser (smfr) 2011-01-17 10:56:50 PST
Comment on attachment 79179 [details]
Paint directly into a GraphicsLayer when using accelerated compositing

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

> Source/WebCore/ChangeLog:11
> +        Remove special-cased support for providing content for the root layer
> +
> +        Clients will just have to provide content through the normal
> +        GraphicsLayer channels now!
> +
> +        Support for <http://webkit.org/b/52582> WebView should paint directly
> +        into a GraphicsLayer when in accelerated compositing mode
> +
> +        Reviewed by NOBODY (OOPS!).

The order of these paragraphs is backwards.

> WebKit/win/ChangeLog:23
> +        Paint directly into a GraphicsLayer when using accelerated compositing
> +
> +        Before this patch, we were painting into our normal backing store
> +        HBITMAP, wrapping it in a CGImage, and handing it off to Core
> +        Animation. This had at least two disadvantages:
> +           1) The bitmap could be modified while Core Animation was using it.
> +           2) It introduced extra complexity.
> +
> +        When entering accelerated compositing mode, WebView now creates a
> +        GraphicsLayer to draw into. This GraphicsLayer sits between the root
> +        layer (owned by WKCACFLayerRenderer) and the RenderView's layer. When
> +        WebView invalidates, it just calls setNeedsDisplayInRect on its
> +        GraphicsLayer. When WebView paints, it just tells its
> +        WKCACFLayerRenderer to paint, which will call back to WebView to draw
> +        into the GraphicsLayer if it has a dirty region. This is very similar
> +        to the current implementation of LayerBackedDrawingArea in WebKit2.
> +
> +        Fixes <http://webkit.org/b/52582> WebView should paint directly into a
> +        GraphicsLayer when in accelerated compositing mode
> +
> +        Reviewed by NOBODY (OOPS!).

Backwards paragraphs.
Comment 3 Adam Roben (:aroben) 2011-01-17 17:52:40 PST
Committed r75987: <http://trac.webkit.org/changeset/75987>