aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2018-03-17 21:16:26 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2018-05-08 23:02:58 +0200
commit1b6c89ca8db2608499949e51f0a38c7ec0a5e921 (patch)
treed81c957ff4c6fcf4a782f99edfc411e45a39a8e7 /libavformat
parent86c92509231f67a2397f0d98530e5dca1720d1f3 (diff)
downloadffmpeg-1b6c89ca8db2608499949e51f0a38c7ec0a5e921.tar.gz
avformat/mxfenc: Add object model version
Other tools (XFConvert at least) write this as well. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/mxfenc.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c
index a9338f7bc3..d5aa11293b 100644
--- a/libavformat/mxfenc.c
+++ b/libavformat/mxfenc.c
@@ -422,6 +422,7 @@ static const MXFLocalTagPair mxf_local_tag_batch[] = {
{ 0x3C0A, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x01,0x01,0x01,0x15,0x02,0x00,0x00,0x00,0x00}}, /* Instance UID */
{ 0x3B02, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x07,0x02,0x01,0x10,0x02,0x04,0x00,0x00}}, /* Last Modified Date */
{ 0x3B05, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x03,0x01,0x02,0x01,0x05,0x00,0x00,0x00}}, /* Version */
+ { 0x3B07, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x03,0x01,0x02,0x01,0x04,0x00,0x00,0x00}}, /* Object Model Version */
{ 0x3B06, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x06,0x01,0x01,0x04,0x06,0x04,0x00,0x00}}, /* Identifications reference */
{ 0x3B03, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x06,0x01,0x01,0x04,0x02,0x01,0x00,0x00}}, /* Content Storage reference */
{ 0x3B09, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x05,0x01,0x02,0x02,0x03,0x00,0x00,0x00,0x00}}, /* Operational Pattern UL */
@@ -681,7 +682,7 @@ static void mxf_write_preface(AVFormatContext *s)
mxf_write_metadata_key(pb, 0x012f00);
PRINT_KEY(s, "preface key", pb->buf_ptr - 16);
- klv_encode_ber_length(pb, 130 + 16LL * DESCRIPTOR_COUNT(mxf->essence_container_count));
+ klv_encode_ber_length(pb, 138 + 16LL * DESCRIPTOR_COUNT(mxf->essence_container_count));
// write preface set uid
mxf_write_local_tag(pb, 16, 0x3C0A);
@@ -696,6 +697,10 @@ static void mxf_write_preface(AVFormatContext *s)
mxf_write_local_tag(pb, 2, 0x3B05);
avio_wb16(pb, 259); // v1.3
+ // Object Model Version
+ mxf_write_local_tag(pb, 4, 0x3B07);
+ avio_wb32(pb, 1);
+
// write identification_refs
mxf_write_local_tag(pb, 16 + 8, 0x3B06);
mxf_write_refs_count(pb, 1);