Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/videolan/dav1d.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2018-11-24 19:23:01 +0300
committerRonald S. Bultje <rsbultje@gmail.com>2018-11-25 21:38:31 +0300
commitb6bb8536ad299d52a5ff49a4f0317b923ce6b8bb (patch)
tree9a331e11077aae3902651ffc0d258286e6ac7ab6 /include
parent3e95d8ed717082430db632d290309f4f7326e7fe (diff)
Store literal bitstream values in Dav1dSequence/FrameHeader
This means storing monochrome, ss_hor/ver and hbd. The derived values bpc and layout are then stored in Dav1dPictureParameters.
Diffstat (limited to 'include')
-rw-r--r--include/dav1d/headers.h10
-rw-r--r--include/dav1d/picture.h3
2 files changed, 9 insertions, 4 deletions
diff --git a/include/dav1d/headers.h b/include/dav1d/headers.h
index cdde681..bf8c5ae 100644
--- a/include/dav1d/headers.h
+++ b/include/dav1d/headers.h
@@ -173,8 +173,6 @@ typedef struct Dav1dSequenceHeader {
* a normative requirement.
*/
int max_width, max_height;
- int bpc; ///< bits per pixel component (8 or 10)
- enum Dav1dPixelLayout layout; ///< format of the picture
enum Dav1dColorPrimaries pri; ///< color primaries (av1)
enum Dav1dTransferCharacteristics trc; ///< transfer characteristics (av1)
enum Dav1dMatrixCoefficients mtrx; ///< matrix coefficients (av1)
@@ -231,7 +229,15 @@ typedef struct Dav1dSequenceHeader {
int super_res;
int cdef;
int restoration;
+ /**
+ * 0, 1 and 2 mean 8, 10 or 12 bits/component, respectively. This is not
+ * exactly the same as 'hbd' from the spec; the spec's hbd distinguishes
+ * between 8 (0) and 10-12 (1) bits/component, and another element
+ * (twelve_bit) to distinguish between 10 and 12 bits/component. To get
+ * the spec's hbd, use !!our_hbd, and to get twelve_bit, use hbd == 2.
+ */
int hbd;
+ int ss_hor, ss_ver, monochrome;
int color_description_present;
int separate_uv_delta_q;
int film_grain_present;
diff --git a/include/dav1d/picture.h b/include/dav1d/picture.h
index bdb26d9..1c51074 100644
--- a/include/dav1d/picture.h
+++ b/include/dav1d/picture.h
@@ -42,7 +42,6 @@ typedef struct Dav1dPictureParameters {
} Dav1dPictureParameters;
typedef struct Dav1dPicture {
- struct Dav1dRef *frame_hdr_ref, *seq_hdr_ref;
Dav1dSequenceHeader *seq_hdr;
Dav1dFrameHeader *frame_hdr;
@@ -54,7 +53,6 @@ typedef struct Dav1dPicture {
* zero'ed out.
*/
void *data[3];
- struct Dav1dRef *ref; ///< allocation origin
/**
* Number of bytes between 2 lines in data[] for luma [0] or chroma [1].
@@ -63,6 +61,7 @@ typedef struct Dav1dPicture {
Dav1dPictureParameters p;
Dav1dDataProps m;
+ struct Dav1dRef *frame_hdr_ref, *seq_hdr_ref, *ref; ///< allocation origins
void *allocator_data; ///< pointer managed by the allocator
} Dav1dPicture;