aboutsummaryrefslogtreecommitdiff
path: root/libgav1/src/gav1/decoder_buffer.h
diff options
context:
space:
mode:
Diffstat (limited to 'libgav1/src/gav1/decoder_buffer.h')
-rw-r--r--libgav1/src/gav1/decoder_buffer.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/libgav1/src/gav1/decoder_buffer.h b/libgav1/src/gav1/decoder_buffer.h
index 880c320..0a5586e 100644
--- a/libgav1/src/gav1/decoder_buffer.h
+++ b/libgav1/src/gav1/decoder_buffer.h
@@ -115,6 +115,27 @@ typedef enum Libgav1ColorRange {
kLibgav1ColorRangeFull // YUV/RGB [0..255]
} Libgav1ColorRange;
+typedef struct Libgav1ObuMetadataHdrCll { // NOLINT
+ uint16_t max_cll; // Maximum content light level.
+ uint16_t max_fall; // Maximum frame-average light level.
+} Libgav1ObuMetadataHdrCll;
+
+typedef struct Libgav1ObuMetadataHdrMdcv { // NOLINT
+ uint16_t primary_chromaticity_x[3];
+ uint16_t primary_chromaticity_y[3];
+ uint16_t white_point_chromaticity_x;
+ uint16_t white_point_chromaticity_y;
+ uint32_t luminance_max;
+ uint32_t luminance_min;
+} Libgav1ObuMetadataHdrMdcv;
+
+typedef struct Libgav1ObuMetadataItutT35 { // NOLINT
+ uint8_t country_code;
+ uint8_t country_code_extension_byte; // Valid if country_code is 0xFF.
+ uint8_t* payload_bytes;
+ int payload_size;
+} Libgav1ObuMetadataItutT35;
+
typedef struct Libgav1DecoderBuffer {
#if defined(__cplusplus)
LIBGAV1_PUBLIC int NumPlanes() const {
@@ -146,6 +167,18 @@ typedef struct Libgav1DecoderBuffer {
// Temporal id of this frame.
int temporal_id;
+ Libgav1ObuMetadataHdrCll hdr_cll;
+ int has_hdr_cll; // 1 if the values in hdr_cll are valid for this frame. 0
+ // otherwise.
+
+ Libgav1ObuMetadataHdrMdcv hdr_mdcv;
+ int has_hdr_mdcv; // 1 if the values in hdr_mdcv are valid for this frame. 0
+ // otherwise.
+
+ Libgav1ObuMetadataItutT35 itut_t35;
+ int has_itut_t35; // 1 if the values in itut_t35 are valid for this frame. 0
+ // otherwise.
+
// The |user_private_data| argument passed to Decoder::EnqueueFrame().
int64_t user_private_data;
// The |private_data| field of FrameBuffer. Set by the get frame buffer
@@ -264,6 +297,10 @@ using ColorRange = Libgav1ColorRange;
constexpr ColorRange kColorRangeStudio = kLibgav1ColorRangeStudio;
constexpr ColorRange kColorRangeFull = kLibgav1ColorRangeFull;
+using ObuMetadataHdrCll = Libgav1ObuMetadataHdrCll;
+using ObuMetadataHdrMdcv = Libgav1ObuMetadataHdrMdcv;
+using ObuMetadataItutT35 = Libgav1ObuMetadataItutT35;
+
using DecoderBuffer = Libgav1DecoderBuffer;
} // namespace libgav1