[webkit-changes] [WebKit/WebKit] b5217d: [Cocoa] Reenable WebCodecs VP9 hardware decoder fo...

youennf noreply at github.com
Tue Jan 30 00:23:58 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: b5217d075329c90195951dcfa4b09446589bc9da
      https://github.com/WebKit/WebKit/commit/b5217d075329c90195951dcfa4b09446589bc9da
  Author: Youenn Fablet <youennf at gmail.com>
  Date:   2024-01-30 (Tue, 30 Jan 2024)

  Changed paths:
    M Source/ThirdParty/libwebrtc/Configurations/libwebrtc.xcconfig
    M Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/components/video_codec/RTCVideoDecoderVTBVP9.mm
    M Source/WebKit/WebProcess/GPU/media/RemoteVideoCodecFactory.cpp

  Log Message:
  -----------
  [Cocoa] Reenable WebCodecs VP9 hardware decoder for AS
rdar://121693406
https://bugs.webkit.org/show_bug.cgi?id=268298

Reviewed by Eric Carlson.

WebCodecs allows to create decoders without width and height.
In that case, for VP9, we retrieve this information from the input format that is parsed.

We can also parse whether we should use video range or full range pixel formats.
We update the buffer pool accordingly.

Finally, we no longer remove the kCVImageBufferCGColorSpaceKey like is done for the H264 decoder as it is necessary to correctly render decoded video frames in canvas.
We instead set it to sRGB.

Covered by imported/w3c/web-platform-tests/webcodecs/full-cycle-test.https.any.html?vp9_p0 for the full range/video range fix.
Covered by imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.https.any.worker.html for the creation of decoder without width and height,
and the right color space usage.

* Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/components/video_codec/RTCVideoDecoderVTBVP9.mm:
(computeInputFormat):
(overrideVP9ColorSpaceAttachments):
(-[RTCVideoDecoderVTBVP9 init]):
(-[RTCVideoDecoderVTBVP9 decodeData:size:timeStamp:]):
(-[RTCVideoDecoderVTBVP9 resetDecompressionSession]):
* Source/WebKit/WebProcess/GPU/media/RemoteVideoCodecFactory.cpp:
(WebKit::shouldUseLocalDecoder):

Canonical link: https://commits.webkit.org/273733@main




More information about the webkit-changes mailing list