Summary: | Implement video hole punching | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Julien Isorce <j.isorce> | ||||||
Component: | Layout and Rendering | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED INVALID | ||||||||
Severity: | Normal | CC: | arkr17997, brian.holt, commit-queue, eric.carlson, jeremyj-wk, jer.noble, jonlee, obzhirov, p.jacquemart, pnormand, rgabor, sam, simon.fraser | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
Julien Isorce
2015-02-13 05:51:35 PST
Created attachment 246519 [details]
Implement video hole punching
Attachment 246519 [details] did not pass style-queue:
ERROR: Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:94: Please declare enum bitfields as unsigned integral types. [runtime/enum_bitfields] [5]
Total errors found: 1 in 17 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 246520 [details]
2 html examples to illustrate hole punching feature.
(I plan to write some layout tests)
Comment on attachment 246519 [details]
Implement video hole punching
This is not something we want to support in WebKit. As Simon noted on webkit-dev, "[hole] is really just adapting to a limitation of the platform’s compositing architecture".
Hole punching is also useful for protected content. Actually the hardware here is really powerful and zero-copy capable (from CPU point of view) for HW decoding into GL rendering. But this way is still not suitable for protected content. The attached patch should have been submitted just after the webkit-dev discussion but for priority reasons it has been delayed. Speaking about the webkit-dev discussion, it was clear for me that a new <hole> tag is definitely a no. But I thought that a capability of <video> tag would have been considered: "The right solution for a WebKit implementation would be to solve this via the accelerated composting code. Just use a <video> or <object> in your markup, then implement the hole-punching via the GraphicsLayer subsystem." It is worth to mention that the implementation is independent of the UI tool kit port. Though I only tested it on GTK and EFL. Also there are 2 parts in this patch, the main part about the platform layer that punch through at compositing time. And the second part that parses background=-webkit-hole for a video tag. In fact in chromium you only have something similar in principle to the first part, so nothing exposed directly from javascript. There is a very recent discussion on chromium-dev about EME and hole punching: https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/P8MDgY9f1RE I see hole punching as an intermediate solution until the good solution will be widely supported by the hardware: "GPU support for composition of protected video " (through OpenGL) In any case we were happy to share the code so serve as generic example, demo or anything else. If it gets interest soon or later in the future, even just few parts of the patch, feel free to reopen the bug and I will be happy to rebase it. |