[WebCodecs] Support GPU VideoFrame for ImageBitmap
This uses yuv_util's ConvertFromVideoFrameYUV to import VideoFrame into SkImage converting YUV to RGB, and then creates AcceleratedStaticBitmapImage with the RGB SkImage. Finally given the AcceleratedStaticBitmapImage, ImageBitmap can be directly constructed from it. In this way, VideoFrame from either software or hardware decoder is supported, and the format may only be NV12 or I420. The current test case only covers software decoder. Once hardware decoder is available, new test case should be added. Bug: 897297 Change-Id: I961bc8506f69f86d395736af458157c53579c81e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2242724Reviewed-by:Dan Sanders <sandersd@chromium.org> Commit-Queue: Jie A Chen <jie.a.chen@intel.com> Cr-Commit-Position: refs/heads/master@{#779627}
Showing
Please register or sign in to comment