1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 08:07:44 +00:00

LibVideo: Add VideoFrame class for decoded video frames

The class is virtual and has one subclass, SubsampledYUVFrame, which
is used by the VP9 decoder to return a single frame. The
output_to_bitmap(Bitmap&) function can be used to set pixels on an
existing bitmap of the correct size to the RGB values that
should be displayed. The to_bitmap() function will allocate a new bitmap
and fill it using output_to_bitmap.

This new class also implements bilinear scaling of the subsampled U and
V planes so that subsampled videos' colors will appear smoother.
This commit is contained in:
Zaggy1024 2022-10-08 18:36:57 -05:00 committed by Andreas Kling
parent 30189186e9
commit 074f771b59
8 changed files with 244 additions and 70 deletions

View file

@ -3,6 +3,7 @@ set(SOURCES
Color/ColorPrimaries.cpp
Color/TransferCharacteristics.cpp
MatroskaReader.cpp
VideoFrame.cpp
VP9/BitStream.cpp
VP9/Decoder.cpp
VP9/Parser.cpp