Bug 57651 - Behavior of isAccelerated() for a IOSurface-backed canvas should be consistent with accelerated status of its ImageBuffer
Summary: Behavior of isAccelerated() for a IOSurface-backed canvas should be consisten...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Canvas (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: Matthew Delaney
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-01 12:39 PDT by Matthew Delaney
Modified: 2011-04-01 14:00 PDT (History)
3 users (show)

See Also:


Attachments
Patch (2.08 KB, patch)
2011-04-01 12:46 PDT, Matthew Delaney
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 Matthew Delaney 2011-04-01 12:39:14 PDT
Currently, if a canvas is backed by an IOSurface, its isAccelerated method simply reports whether or not the page settings have canvasUsesAcceleratedDrawing enabled. This leads to an inconsistency because having that preference on isn't a sufficient condition for an accelerated canvas backend (e.g. when the IOSurface backend is avoided due to size limits). Thus, when the canvas is backed by an IOSurface then isAccelerated on the context should only report true when the ImageBuffer is in fact in Accelerated Rendering mode (i.e. it did in fact create an IOSurface backing).
Comment 1 Matthew Delaney 2011-04-01 12:46:57 PDT
Created attachment 87899 [details]
Patch
Comment 2 Simon Fraser (smfr) 2011-04-01 13:09:51 PDT
Comment on attachment 87899 [details]
Patch

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

> Source/WebCore/platform/graphics/ImageBuffer.h:89
> +        bool isAccelerated() { return m_accelerateRendering; }

This should be |const|
Comment 3 Matthew Delaney 2011-04-01 14:00:37 PDT
Committed r82715: <http://trac.webkit.org/changeset/82715>