[webkit-changes] [WebKit/WebKit] ec0b08: Add WebCodecs VideoFrame support for createImageBi...

youennf noreply at github.com
Thu Oct 20 00:17:12 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ec0b08a9250928a5b0712db55011517734bdecef
      https://github.com/WebKit/WebKit/commit/ec0b08a9250928a5b0712db55011517734bdecef
  Author: Youenn Fablet <youennf at gmail.com>
  Date:   2022-10-20 (Thu, 20 Oct 2022)

  Changed paths:
    M LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-alpha.any-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-canvasImageSource-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-construction.any-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.any-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.any.worker-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.https.any-expected.txt
    M Source/WebCore/Modules/webcodecs/WebCodecsVideoFrame.h
    M Source/WebCore/Modules/webcodecs/WebCodecsVideoFrameAlgorithms.cpp
    M Source/WebCore/html/ImageBitmap.cpp
    M Source/WebCore/html/ImageBitmap.h
    M Source/WebCore/page/WindowOrWorkerGlobalScope.idl
    M Source/WebCore/platform/graphics/cv/VideoFrameCV.mm

  Log Message:
  -----------
  Add WebCodecs VideoFrame support for createImageBitmap
https://bugs.webkit.org/show_bug.cgi?id=246739
rdar://problem/101331058

Reviewed by Eric Carlson.

Update WebIDL to support WebCodecsVideoFrame as input to createImageBitmap.
Reuse VideoFrame::paintInContext to create the ImageBitmap.
Fix WebCodecsVideoFrame to crrectly set visible rect and displayWidth/displayHeight.

* LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-alpha.any-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-canvasImageSource-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-construction.any-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.any-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.any.worker-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/webcodecs/videoFrame-createImageBitmap.https.any-expected.txt:
* Source/WebCore/Modules/webcodecs/WebCodecsVideoFrame.h:
* Source/WebCore/Modules/webcodecs/WebCodecsVideoFrameAlgorithms.cpp:
(WebCore::initializeVisibleRectAndDisplaySize):
* Source/WebCore/html/ImageBitmap.cpp:
(WebCore::ImageBitmap::createPromise):
* Source/WebCore/html/ImageBitmap.h:
* Source/WebCore/page/WindowOrWorkerGlobalScope.idl:
* Source/WebCore/platform/graphics/cv/VideoFrameCV.mm:
(WebCore::VideoFrame::paintInContext):

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




More information about the webkit-changes mailing list