[webkit-changes] [WebKit/WebKit] f651a6: [Cocoa] Encrypted video does not play when not in ...
Jer Noble
noreply at github.com
Thu Nov 17 15:33:46 PST 2022
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: f651a6b237e78a2c1fc9493214a3caac5f0852f5
https://github.com/WebKit/WebKit/commit/f651a6b237e78a2c1fc9493214a3caac5f0852f5
Author: Jer Noble <jer.noble at apple.com>
Date: 2022-11-17 (Thu, 17 Nov 2022)
Changed paths:
A LayoutTests/http/tests/media/fairplay/fps-mse-play-while-not-in-dom-expected.txt
A LayoutTests/http/tests/media/fairplay/fps-mse-play-while-not-in-dom.html
M Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h
M Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm
M Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h
M Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm
Log Message:
-----------
[Cocoa] Encrypted video does not play when not in the DOM
https://bugs.webkit.org/show_bug.cgi?id=248008
rdar://102446042
Reviewed by Eric Carlson.
WebCoreDecompressionSession isn't capable (by design) of decoding encrypted content. When
a video element is not in the DOM, a decompression session is created to allow the element
to be painted into a canvas. But since decoding encrypted samples will always fail, always
create an AVSampleBufferDisplayLayer if any SourceBuffer has an enabled, protected video track.
* LayoutTests/http/tests/media/fairplay/fps-mse-play-while-not-in-dom-expected.txt: Added.
* LayoutTests/http/tests/media/fairplay/fps-mse-play-while-not-in-dom.html: Added.
* Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
* Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::shouldEnsureLayer const):
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::needsVideoLayerChanged):
* Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
* Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
(WebCore::SourceBufferPrivateAVFObjC::didProvideContentKeyRequestInitializationDataForTrackID):
(WebCore::SourceBufferPrivateAVFObjC::needsVideoLayer const):
(WebCore::SourceBufferPrivateAVFObjC::trackDidChangeSelected):
(WebCore::SourceBufferPrivateAVFObjC::canEnqueueSample):
Canonical link: https://commits.webkit.org/256805@main
More information about the webkit-changes
mailing list