FFmpeg
dovi_rpu.c
Go to the documentation of this file.
1 /*
2  * This file is part of FFmpeg.
3  *
4  * FFmpeg is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * FFmpeg is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with FFmpeg; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17  */
18 
19 #include "libavutil/common.h"
20 #include "libavutil/mem.h"
21 #include "libavutil/opt.h"
22 
23 #include "bsf.h"
24 #include "bsf_internal.h"
25 #include "cbs.h"
26 #include "cbs_bsf.h"
27 #include "cbs_av1.h"
28 #include "cbs_h265.h"
29 #include "dovi_rpu.h"
30 #include "h2645data.h"
31 #include "h265_profile_level.h"
32 #include "itut35.h"
33 
34 #include "hevc/hevc.h"
35 
36 typedef struct DoviRpuContext {
40 
41  int strip;
44 
45 static int update_rpu(AVBSFContext *bsf, const AVPacket *pkt, int flags,
46  const uint8_t *rpu, size_t rpu_size,
47  uint8_t **out_rpu, int *out_size)
48 {
49  DoviRpuContext *s = bsf->priv_data;
50  AVDOVIMetadata *metadata = NULL;
51  int ret;
52 
53  ret = ff_dovi_rpu_parse(&s->dec, rpu, rpu_size, 0);
54  if (ret < 0) {
55  ff_dovi_ctx_flush(&s->dec);
56  return ret;
57  }
58 
59  ret = ff_dovi_get_metadata(&s->dec, &metadata);
60  if (ret == 0 /* no metadata */) {
61  *out_rpu = NULL;
62  *out_size = 0;
63  return 0;
64  } else if (ret < 0) {
65  ff_dovi_ctx_flush(&s->dec);
66  return ret;
67  }
68 
69  if (pkt && !(pkt->flags & AV_PKT_FLAG_KEY))
71  ret = ff_dovi_rpu_generate(&s->enc, metadata, flags, out_rpu, out_size);
72  av_free(metadata);
73  if (ret < 0)
74  ff_dovi_ctx_flush(&s->enc);
75 
76  return ret;
77 }
78 
81 {
82  DoviRpuContext *s = bsf->priv_data;
83  CodedBitstreamUnit *nal = au->nb_units ? &au->units[au->nb_units - 1] : NULL;
84  uint8_t *rpu = NULL;
85  int rpu_size, ret;
86 
87  // HEVC_NAL_UNSPEC62 is Dolby Vision PRU and HEVC_NAL_UNSPEC63 is Dolby Vision EL
88  if (!nal || (nal->type != HEVC_NAL_UNSPEC62 && nal->type != HEVC_NAL_UNSPEC63))
89  return 0;
90 
91  if (s->strip) {
92  ff_cbs_delete_unit(au, au->nb_units - 1);
93  return 0;
94  }
95 
96  if (nal->type == HEVC_NAL_UNSPEC63)
97  return 0;
98 
99  ret = update_rpu(bsf, pkt, 0, nal->data + 2, nal->data_size - 2, &rpu, &rpu_size);
100  if (ret < 0)
101  return ret;
102 
103  /* NAL unit header + NAL prefix */
104  if (rpu_size + 3 <= nal->data_size && av_buffer_is_writable(nal->data_ref)) {
105  memcpy(nal->data + 3, rpu, rpu_size);
106  av_free(rpu);
107  nal->data_size = rpu_size + 3;
108  } else {
109  AVBufferRef *ref = av_buffer_alloc(rpu_size + 3);
110  if (!ref) {
111  av_free(rpu);
112  return AVERROR(ENOMEM);
113  }
114 
115  memcpy(ref->data, nal->data, 3);
116  memcpy(ref->data + 3, rpu, rpu_size);
117  av_buffer_unref(&nal->data_ref);
118  av_free(rpu);
119  nal->data = ref->data;
120  nal->data_size = rpu_size + 3;
121  nal->data_ref = ref;
122  nal->data_bit_padding = 0;
123  }
124 
125  return 0;
126 }
127 
130 {
131  DoviRpuContext *s = bsf->priv_data;
132  int provider_code, provider_oriented_code, rpu_size, ret;
133  AVBufferRef *ref;
134  uint8_t *rpu;
135 
136  for (int i = 0; i < frag->nb_units; i++) {
137  AV1RawOBU *obu = frag->units[i].content;
139  if (frag->units[i].type != AV1_OBU_METADATA ||
142  t35->payload_size < 6)
143  continue;
144 
145  provider_code = AV_RB16(t35->payload);
146  provider_oriented_code = AV_RB32(t35->payload + 2);
147  if (provider_code != ITU_T_T35_PROVIDER_CODE_DOLBY ||
148  provider_oriented_code != 0x800)
149  continue;
150 
151  if (s->strip) {
152  ff_cbs_delete_unit(frag, i);
153  return 0;
154  }
155 
157  t35->payload + 6, t35->payload_size - 6,
158  &rpu, &rpu_size);
159  if (ret < 0)
160  return ret;
161 
162  ref = av_buffer_create(rpu, rpu_size, av_buffer_default_free, NULL, 0);
163  if (!ref) {
164  av_free(rpu);
165  return AVERROR(ENOMEM);
166  }
167 
169  t35->payload_ref = ref;
170  t35->payload = rpu + 1; /* skip country code */
171  t35->payload_size = rpu_size - 1;
172  break; /* should be only one RPU per packet */
173  }
174 
175  return 0;
176 }
177 
180  .fragment_name = "access unit",
181  .unit_name = "NAL unit",
182  .update_fragment = &dovi_rpu_update_fragment_hevc,
183 };
184 
187  .fragment_name = "temporal unit",
188  .unit_name = "OBU",
189  .update_fragment = &dovi_rpu_update_fragment_av1,
190 };
191 
192 static int dovi_rpu_init(AVBSFContext *bsf)
193 {
194  int ret;
195  DoviRpuContext *s = bsf->priv_data;
196  s->dec.logctx = s->enc.logctx = bsf;
197  s->enc.enable = 1;
198 
199  if (s->compression == AV_DOVI_COMPRESSION_RESERVED) {
200  av_log(bsf, AV_LOG_ERROR, "Invalid compression level: %d\n", s->compression);
201  return AVERROR(EINVAL);
202  }
203 
204  if (s->strip) {
208  } else {
209  const AVPacketSideData *sd;
213 
214  if (sd) {
217  s->dec.cfg = *cfg;
218 
219  /* Update configuration record before setting to enc ctx */
220  cfg->dv_md_compression = s->compression;
221  if (s->compression && s->dec.cfg.dv_profile < 8) {
222  av_log(bsf, AV_LOG_ERROR, "Invalid compression level %d for "
223  "Dolby Vision profile %d.\n", s->compression, s->dec.cfg.dv_profile);
224  return AVERROR(EINVAL);
225  }
226 
227  s->enc.cfg = *cfg;
228  } else {
229  av_log(bsf, AV_LOG_WARNING, "No Dolby Vision configuration record "
230  "found? Generating one, but results may be invalid.\n");
231  ret = ff_dovi_configure_ext(&s->enc, bsf->par_out, NULL, s->compression,
233  if (ret < 0)
234  return ret;
235  /* Be conservative in accepting all compressed RPUs */
236  s->dec.cfg = s->enc.cfg;
237  s->dec.cfg.dv_md_compression = AV_DOVI_COMPRESSION_EXTENDED;
238  }
239  }
240 
241  switch (bsf->par_in->codec_id) {
242  case AV_CODEC_ID_HEVC:
244  case AV_CODEC_ID_AV1:
246  default:
247  return AVERROR_BUG;
248  }
249 }
250 
251 static void dovi_rpu_close(AVBSFContext *bsf)
252 {
253  DoviRpuContext *s = bsf->priv_data;
254  ff_dovi_ctx_unref(&s->dec);
255  ff_dovi_ctx_unref(&s->enc);
257 }
258 
259 #define OFFSET(x) offsetof(DoviRpuContext, x)
260 #define FLAGS (AV_OPT_FLAG_VIDEO_PARAM|AV_OPT_FLAG_BSF_PARAM)
261 static const AVOption dovi_rpu_options[] = {
262  { "strip", "Strip Dolby Vision metadata", OFFSET(strip), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, FLAGS },
263  { "compression", "DV metadata compression mode", OFFSET(compression), AV_OPT_TYPE_INT, { .i64 = AV_DOVI_COMPRESSION_LIMITED }, 0, AV_DOVI_COMPRESSION_EXTENDED, FLAGS, .unit = "compression" },
264  { "none", "Don't compress metadata", 0, AV_OPT_TYPE_CONST, {.i64 = 0}, .flags = FLAGS, .unit = "compression" },
265  { "limited", "Limited metadata compression", 0, AV_OPT_TYPE_CONST, {.i64 = AV_DOVI_COMPRESSION_LIMITED}, .flags = FLAGS, .unit = "compression" },
266  { "extended", "Extended metadata compression",0, AV_OPT_TYPE_CONST, {.i64 = AV_DOVI_COMPRESSION_EXTENDED}, .flags = FLAGS, .unit = "compression" },
267  { NULL }
268 };
269 
270 static const AVClass dovi_rpu_class = {
271  .class_name = "dovi_rpu_bsf",
272  .item_name = av_default_item_name,
273  .option = dovi_rpu_options,
274  .version = LIBAVUTIL_VERSION_INT,
275 };
276 
277 static const enum AVCodecID dovi_rpu_codec_ids[] = {
279 };
280 
282  .p.name = "dovi_rpu",
283  .p.codec_ids = dovi_rpu_codec_ids,
284  .p.priv_class = &dovi_rpu_class,
285  .priv_data_size = sizeof(DoviRpuContext),
286  .init = &dovi_rpu_init,
287  .close = &dovi_rpu_close,
289 };
AVBSFContext::par_in
AVCodecParameters * par_in
Parameters of the input stream.
Definition: bsf.h:90
AV_LOG_WARNING
#define AV_LOG_WARNING
Something somehow does not look correct.
Definition: log.h:215
DoviRpuContext::enc
DOVIContext enc
Definition: dovi_rpu.c:39
ff_cbs_bsf_generic_init
int ff_cbs_bsf_generic_init(AVBSFContext *bsf, const CBSBSFType *type)
Initialise generic CBS BSF setup.
Definition: cbs_bsf.c:110
AVERROR
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel sample they are references to shared objects When the negotiation mechanism computes the intersection of the formats supported at each end of a all references to both lists are replaced with a reference to the intersection And when a single format is eventually chosen for a link amongst the remaining all references to the list are updated That means that if a filter requires that its input and output have the same format amongst a supported all it has to do is use a reference to the same list of formats query_formats can leave some formats unset and return AVERROR(EAGAIN) to cause the negotiation mechanism toagain later. That can be used by filters with complex requirements to use the format negotiated on one link to set the formats supported on another. Frame references ownership and permissions
bsf_internal.h
opt.h
ff_dovi_ctx_unref
void ff_dovi_ctx_unref(DOVIContext *s)
Completely reset a DOVIContext, preserving only logctx.
Definition: dovi_rpu.c:29
ff_dovi_rpu_bsf
const FFBitStreamFilter ff_dovi_rpu_bsf
Definition: dovi_rpu.c:281
CBSBSFType::codec_id
enum AVCodecID codec_id
Definition: cbs_bsf.h:32
FLAGS
#define FLAGS
Definition: dovi_rpu.c:260
AV_DOVI_COMPRESSION_LIMITED
@ AV_DOVI_COMPRESSION_LIMITED
Definition: dovi_meta.h:69
CodedBitstreamUnit::content
void * content
Pointer to the decomposed form of this unit.
Definition: cbs.h:107
ff_dovi_rpu_parse
int ff_dovi_rpu_parse(DOVIContext *s, const uint8_t *rpu, size_t rpu_size, int err_recognition)
Parse the contents of a Dolby Vision RPU and update the parsed values in the DOVIContext struct.
Definition: dovi_rpudec.c:346
AVBitStreamFilter::name
const char * name
Definition: bsf.h:112
out_size
int out_size
Definition: movenc.c:56
AVPacketSideData
This structure stores auxiliary information for decoding, presenting, or otherwise processing the cod...
Definition: packet.h:390
AVOption
AVOption.
Definition: opt.h:429
av_packet_side_data_remove
void av_packet_side_data_remove(AVPacketSideData *sd, int *pnb_sd, enum AVPacketSideDataType type)
Remove side data of the given type from a side data array.
Definition: packet.c:729
update_rpu
static int update_rpu(AVBSFContext *bsf, const AVPacket *pkt, int flags, const uint8_t *rpu, size_t rpu_size, uint8_t **out_rpu, int *out_size)
Definition: dovi_rpu.c:45
CBSBSFContext
Definition: cbs_bsf.h:53
filter
void(* filter)(uint8_t *src, int stride, int qscale)
Definition: h263dsp.c:29
CodedBitstreamUnit::type
CodedBitstreamUnitType type
Codec-specific type of this unit.
Definition: cbs.h:74
cbs.h
cbs_h265.h
AV1_METADATA_TYPE_ITUT_T35
@ AV1_METADATA_TYPE_ITUT_T35
Definition: av1.h:47
AV_PKT_FLAG_KEY
#define AV_PKT_FLAG_KEY
The packet contains a keyframe.
Definition: packet.h:594
AVBSFContext
The bitstream filter state.
Definition: bsf.h:68
AV1RawMetadata::itut_t35
AV1RawMetadataITUTT35 itut_t35
Definition: cbs_av1.h:387
CodedBitstreamUnit
Coded bitstream unit structure.
Definition: cbs.h:70
AV_PKT_DATA_DOVI_CONF
@ AV_PKT_DATA_DOVI_CONF
DOVI configuration ref: dolby-vision-bitstreams-within-the-iso-base-media-file-format-v2....
Definition: packet.h:280
dovi_rpu_update_fragment_av1
static int dovi_rpu_update_fragment_av1(AVBSFContext *bsf, AVPacket *pkt, CodedBitstreamFragment *frag)
Definition: dovi_rpu.c:128
dovi_rpu_close
static void dovi_rpu_close(AVBSFContext *bsf)
Definition: dovi_rpu.c:251
bsf.h
cbs_bsf.h
DOVIContext
Definition: dovi_rpu.h:42
AV_DOVI_COMPRESSION_EXTENDED
@ AV_DOVI_COMPRESSION_EXTENDED
Definition: dovi_meta.h:71
AVDOVIDecoderConfigurationRecord::dv_md_compression
uint8_t dv_md_compression
Definition: dovi_meta.h:64
AV1RawMetadataITUTT35::payload_size
size_t payload_size
Definition: cbs_av1.h:356
dovi_rpu.h
CodedBitstreamUnit::data
uint8_t * data
Pointer to the directly-parsable bitstream form of this unit.
Definition: cbs.h:81
AVBSFContext::par_out
AVCodecParameters * par_out
Parameters of the output stream.
Definition: bsf.h:96
FF_DOVI_WRAP_T35
@ FF_DOVI_WRAP_T35
wrap inside T.35+EMDF
Definition: dovi_rpu.h:159
FF_DOVI_COMPRESS_RPU
@ FF_DOVI_COMPRESS_RPU
enable compression for this RPU
Definition: dovi_rpu.h:160
CodedBitstreamFragment::units
CodedBitstreamUnit * units
Pointer to an array of units of length nb_units_allocated.
Definition: cbs.h:168
cbs_av1.h
pkt
AVPacket * pkt
Definition: movenc.c:60
AV_LOG_ERROR
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
Definition: log.h:209
CodedBitstreamFragment
Coded bitstream fragment structure, combining one or more units.
Definition: cbs.h:122
AVDOVIMetadata
Combined struct representing a combination of header, mapping and color metadata, for attaching to fr...
Definition: dovi_meta.h:337
s
#define s(width, name)
Definition: cbs_vp9.c:198
HEVC_NAL_UNSPEC62
@ HEVC_NAL_UNSPEC62
Definition: hevc.h:91
av_buffer_default_free
void av_buffer_default_free(void *opaque, uint8_t *data)
Default free callback, which calls av_free() on the buffer data.
Definition: buffer.c:72
AVPacketSideData::data
uint8_t * data
Definition: packet.h:391
hevc.h
AVCodecParameters::nb_coded_side_data
int nb_coded_side_data
Amount of entries in coded_side_data.
Definition: codec_par.h:86
h2645data.h
if
if(ret)
Definition: filter_design.txt:179
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
AV1RawOBU
Definition: cbs_av1.h:400
AVClass
Describe the class of an AVClass context structure.
Definition: log.h:75
NULL
#define NULL
Definition: coverity.c:32
dovi_rpu_codec_ids
static enum AVCodecID dovi_rpu_codec_ids[]
Definition: dovi_rpu.c:277
FFBitStreamFilter
Definition: bsf_internal.h:27
av_buffer_unref
void av_buffer_unref(AVBufferRef **buf)
Free a given reference and automatically free the buffer if there are no more references to it.
Definition: buffer.c:139
AV_CODEC_ID_AV1
@ AV_CODEC_ID_AV1
Definition: codec_id.h:284
ff_dovi_rpu_generate
int ff_dovi_rpu_generate(DOVIContext *s, const AVDOVIMetadata *metadata, int flags, uint8_t **out_rpu, int *out_size)
Synthesize a Dolby Vision RPU reflecting the current state.
Definition: dovi_rpuenc.c:562
ff_dovi_configure_ext
int ff_dovi_configure_ext(DOVIContext *s, AVCodecParameters *codecpar, const AVDOVIMetadata *metadata, enum AVDOVICompression compression, int strict_std_compliance)
Configure the encoder for Dolby Vision encoding.
Definition: dovi_rpuenc.c:55
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:237
CodedBitstreamUnit::data_size
size_t data_size
The number of bytes in the bitstream (including any padding bits in the final byte).
Definition: cbs.h:86
dovi_rpu_class
static const AVClass dovi_rpu_class
Definition: dovi_rpu.c:270
DoviRpuContext::dec
DOVIContext dec
Definition: dovi_rpu.c:38
AV1RawMetadata::metadata
union AV1RawMetadata::@66 metadata
av_buffer_create
AVBufferRef * av_buffer_create(uint8_t *data, size_t size, void(*free)(void *opaque, uint8_t *data), void *opaque, int flags)
Create an AVBuffer from an existing array.
Definition: buffer.c:55
AVCodecID
AVCodecID
Identify the syntax and semantics of the bitstream.
Definition: codec_id.h:49
av_packet_side_data_get
const AVPacketSideData * av_packet_side_data_get(const AVPacketSideData *sd, int nb_sd, enum AVPacketSideDataType type)
Get side information from a side data array.
Definition: packet.c:657
DoviRpuContext
Definition: dovi_rpu.c:36
FFBitStreamFilter::p
AVBitStreamFilter p
The public AVBitStreamFilter.
Definition: bsf_internal.h:31
ITU_T_T35_PROVIDER_CODE_DOLBY
#define ITU_T_T35_PROVIDER_CODE_DOLBY
Definition: itut35.h:28
init
int(* init)(AVBSFContext *ctx)
Definition: dts2pts.c:368
AV1RawOBU::obu
union AV1RawOBU::@67 obu
ff_dovi_ctx_flush
void ff_dovi_ctx_flush(DOVIContext *s)
Partially reset the internal state.
Definition: dovi_rpu.c:42
dovi_rpu_update_fragment_hevc
static int dovi_rpu_update_fragment_hevc(AVBSFContext *bsf, AVPacket *pkt, CodedBitstreamFragment *au)
Definition: dovi_rpu.c:79
CBSBSFType
Definition: cbs_bsf.h:31
CodedBitstreamUnit::data_bit_padding
size_t data_bit_padding
The number of bits which should be ignored in the final byte.
Definition: cbs.h:92
AV_RB32
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_WL16 uint64_t_TMPL AV_WB64 unsigned int_TMPL AV_RB32
Definition: bytestream.h:96
ff_cbs_bsf_generic_close
void ff_cbs_bsf_generic_close(AVBSFContext *bsf)
Close a generic CBS BSF instance.
Definition: cbs_bsf.c:155
h265_profile_level.h
DoviRpuContext::strip
int strip
Definition: dovi_rpu.c:41
FF_COMPLIANCE_NORMAL
#define FF_COMPLIANCE_NORMAL
Definition: defs.h:60
AVPacket::flags
int flags
A combination of AV_PKT_FLAG values.
Definition: packet.h:545
av_buffer_alloc
AVBufferRef * av_buffer_alloc(size_t size)
Allocate an AVBuffer of the given size using av_malloc().
Definition: buffer.c:77
dovi_rpu_hevc_type
static const CBSBSFType dovi_rpu_hevc_type
Definition: dovi_rpu.c:178
AV1RawOBU::metadata
AV1RawMetadata metadata
Definition: cbs_av1.h:411
AV1RawMetadata::metadata_type
uint64_t metadata_type
Definition: cbs_av1.h:382
DoviRpuContext::compression
int compression
Definition: dovi_rpu.c:42
ff_dovi_get_metadata
int ff_dovi_get_metadata(DOVIContext *s, AVDOVIMetadata **out_metadata)
Get the decoded AVDOVIMetadata.
Definition: dovi_rpudec.c:33
AV_CODEC_ID_NONE
@ AV_CODEC_ID_NONE
Definition: codec_id.h:50
i
#define i(width, name, range_min, range_max)
Definition: cbs_h2645.c:256
CodedBitstreamUnit::data_ref
AVBufferRef * data_ref
A reference to the buffer containing data.
Definition: cbs.h:98
common.h
AV_CODEC_ID_HEVC
@ AV_CODEC_ID_HEVC
Definition: codec_id.h:228
DoviRpuContext::common
CBSBSFContext common
Definition: dovi_rpu.c:37
AV1RawMetadataITUTT35::payload
uint8_t * payload
Definition: cbs_av1.h:354
dovi_rpu_init
static int dovi_rpu_init(AVBSFContext *bsf)
Definition: dovi_rpu.c:192
AVCodecParameters::coded_side_data
AVPacketSideData * coded_side_data
Additional data associated with the entire stream.
Definition: codec_par.h:81
dovi_rpu_av1_type
static const CBSBSFType dovi_rpu_av1_type
Definition: dovi_rpu.c:185
AV1RawMetadataITUTT35::payload_ref
AVBufferRef * payload_ref
Definition: cbs_av1.h:355
av_buffer_is_writable
int av_buffer_is_writable(const AVBufferRef *buf)
Definition: buffer.c:147
AVBSFContext::priv_data
void * priv_data
Opaque filter-specific private data.
Definition: bsf.h:83
ff_cbs_bsf_generic_filter
int ff_cbs_bsf_generic_filter(AVBSFContext *bsf, AVPacket *pkt)
Filter operation for CBS BSF.
Definition: cbs_bsf.c:61
ret
ret
Definition: filter_design.txt:187
AVClass::class_name
const char * class_name
The name of the class; usually it is the same name as the context structure type to which the AVClass...
Definition: log.h:80
OFFSET
#define OFFSET(x)
Definition: dovi_rpu.c:259
AV1RawMetadataITUTT35
Definition: cbs_av1.h:350
itut35.h
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Underlying C type is int.
Definition: opt.h:259
ref
static int ref[MAX_W *MAX_W]
Definition: jpeg2000dwt.c:117
mem.h
AVBufferRef
A reference to a data buffer.
Definition: buffer.h:82
AV1RawMetadataITUTT35::itu_t_t35_country_code
uint8_t itu_t_t35_country_code
Definition: cbs_av1.h:351
ITU_T_T35_COUNTRY_CODE_US
#define ITU_T_T35_COUNTRY_CODE_US
Definition: itut35.h:24
av_free
#define av_free(p)
Definition: tableprint_vlc.h:33
HEVC_NAL_UNSPEC63
@ HEVC_NAL_UNSPEC63
Definition: hevc.h:92
AVCodecParameters::codec_id
enum AVCodecID codec_id
Specific type of the encoded data (the codec used).
Definition: codec_par.h:55
AVPacket
This structure stores compressed data.
Definition: packet.h:516
AV_OPT_TYPE_BOOL
@ AV_OPT_TYPE_BOOL
Underlying C type is int.
Definition: opt.h:327
flags
#define flags(name, subs,...)
Definition: cbs_av1.c:482
AVERROR_BUG
#define AVERROR_BUG
Internal bug, also see AVERROR_BUG2.
Definition: error.h:52
av_log
#define av_log(a,...)
Definition: tableprint_vlc.h:27
dovi_rpu_options
static const AVOption dovi_rpu_options[]
Definition: dovi_rpu.c:261
AV_DOVI_COMPRESSION_RESERVED
@ AV_DOVI_COMPRESSION_RESERVED
Definition: dovi_meta.h:70
AV_OPT_TYPE_CONST
@ AV_OPT_TYPE_CONST
Special option type for declaring named constants.
Definition: opt.h:299
AV1_OBU_METADATA
@ AV1_OBU_METADATA
Definition: av1.h:34
CodedBitstreamFragment::nb_units
int nb_units
Number of units in this fragment.
Definition: cbs.h:153
ff_cbs_delete_unit
void ff_cbs_delete_unit(CodedBitstreamFragment *frag, int position)
Delete a unit from a fragment and free all memory it uses.
Definition: cbs.c:860
AV_RB16
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_WL16 uint64_t_TMPL AV_WB64 unsigned int_TMPL AV_WB32 unsigned int_TMPL AV_WB24 unsigned int_TMPL AV_RB16
Definition: bytestream.h:98
AVDOVIDecoderConfigurationRecord
Definition: dovi_meta.h:55