Bug 149422 - MediaControlTextTrackContainerElement::createTextTrackRepresentationImage makes an unconditionally unaccelerated ImageBuffer
Summary: MediaControlTextTrackContainerElement::createTextTrackRepresentationImage mak...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Matthew Daiter
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-21 15:38 PDT by Tim Horton
Modified: 2015-12-06 19:41 PST (History)
5 users (show)

See Also:


Attachments
Patch (2.25 KB, patch)
2015-12-06 07:08 PST, Matthew Daiter
no flags Details | Formatted Diff | Diff
Patch (2.03 KB, patch)
2015-12-06 07:35 PST, Matthew Daiter
no flags Details | Formatted Diff | Diff
Patch (2.14 KB, patch)
2015-12-06 07:39 PST, Matthew Daiter
no flags Details | Formatted Diff | Diff
Patch (2.15 KB, patch)
2015-12-06 07:41 PST, Matthew Daiter
simon.fraser: review-
simon.fraser: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Horton 2015-09-21 15:38:56 PDT
The ImageBuffer should inherit the accelerated bit from the context it will eventually be painted into.
Comment 1 Matthew Daiter 2015-12-06 07:08:50 PST
Created attachment 266728 [details]
Patch
Comment 2 WebKit Commit Bot 2015-12-06 07:11:09 PST
Attachment 266728 [details] did not pass style-queue:


ERROR: Source/WebCore/html/shadow/MediaControlElements.cpp:1374:  Multi line control clauses should use braces.  [whitespace/braces] [4]
Total errors found: 1 in 2 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Matthew Daiter 2015-12-06 07:35:42 PST
Created attachment 266729 [details]
Patch
Comment 4 Matthew Daiter 2015-12-06 07:38:46 PST
Realized some might be a bit confused by this block:

CanvasCompositingStrategy compositingStrategy = canvasCompositingStrategy(*renderer);
if (compositingStrategy != CanvasCompositingStrategy::UnacceleratedCanvas)
    accelerate = Accelerated;

due to its ignorance of UnacceleratedNonPlatformBuffer as a viable option for the value of accelerate. The reasoning behind this is that--upon searching the entire codebase--UnacceleratedNonPlatformBuffer is not used throughout WebCore. Therefore, if the canvas is not unaccelerated, we treat it as accelerated; otherwise, it becomes unaccelerated.
Comment 5 Matthew Daiter 2015-12-06 07:39:56 PST
Created attachment 266730 [details]
Patch
Comment 6 Matthew Daiter 2015-12-06 07:41:10 PST
Created attachment 266731 [details]
Patch
Comment 7 Simon Fraser (smfr) 2015-12-06 19:41:25 PST
Comment on attachment 266731 [details]
Patch

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

> Source/WebCore/html/shadow/MediaControlElements.cpp:1373
> +    CanvasCompositingStrategy compositingStrategy = canvasCompositingStrategy(*renderer);

I'm not sure what you're trying to do here. 'renderer' is not a RenderHTMLCanvas here, but canvasCompositingStrategy asserts that it is.

Did you test this in debug?