mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 17:17:45 +00:00
LibVideo: Implement CICP color space conversion
This adds a struct called CodingIndependentCodePoints and related enums that are used by video codecs to define its color space that frames must be converted from when displaying a video. Pre-multiplied matrices and lookup tables are stored to avoid most of the floating point division and exponentiation in the conversion.
This commit is contained in:
parent
ba79de0439
commit
cd127b65c3
15 changed files with 935 additions and 18 deletions
|
@ -10,6 +10,7 @@
|
|||
#include <AK/ByteBuffer.h>
|
||||
#include <AK/Error.h>
|
||||
#include <AK/Span.h>
|
||||
#include <LibVideo/Color/CodingIndependentCodePoints.h>
|
||||
#include <LibVideo/DecoderError.h>
|
||||
|
||||
#include "Parser.h"
|
||||
|
@ -32,6 +33,8 @@ public:
|
|||
Gfx::Size<size_t> get_y_plane_size();
|
||||
bool get_uv_subsampling_y();
|
||||
bool get_uv_subsampling_x();
|
||||
CodingIndependentCodePoints get_cicp_color_space();
|
||||
u8 get_bit_depth();
|
||||
|
||||
private:
|
||||
typedef i32 Intermediate;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue