aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/mxfenc.c
diff options
context:
space:
mode:
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>2009-02-10 06:14:39 +0000
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>2009-02-10 06:14:39 +0000
commitee1f7f4bf9cec6bd2da6bf97535fabce5d0ffad4 (patch)
tree5f58851237d7ee45ca7a167b37ab19c435b5bec6 /libavformat/mxfenc.c
parent7be3405291ff0fc59e4ca05cd5379383ffef815c (diff)
downloadffmpeg-ee1f7f4bf9cec6bd2da6bf97535fabce5d0ffad4.tar.gz
write component depth and horizontal subsampling best effort local tags
Originally committed as revision 17120 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/mxfenc.c')
-rw-r--r--libavformat/mxfenc.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c
index 9cd5a40069..1b6205423d 100644
--- a/libavformat/mxfenc.c
+++ b/libavformat/mxfenc.c
@@ -202,6 +202,9 @@ static const MXFLocalTagPair mxf_local_tag_batch[] = {
{ 0x3208, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x01,0x04,0x01,0x05,0x01,0x0B,0x00,0x00,0x00}}, /* Display Height */
{ 0x320E, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x01,0x04,0x01,0x01,0x01,0x01,0x00,0x00,0x00}}, /* Aspect Ratio */
{ 0x3201, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x04,0x01,0x06,0x01,0x00,0x00,0x00,0x00}}, /* Picture Essence Coding */
+ // CDCI Picture Essence Descriptor
+ { 0x3301, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x02,0x04,0x01,0x05,0x03,0x0A,0x00,0x00,0x00}}, /* Component Depth */
+ { 0x3302, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x01,0x04,0x01,0x05,0x01,0x05,0x00,0x00,0x00}}, /* Horizontal Subsampling */
// Generic Sound Essence Descriptor
{ 0x3D02, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x04,0x04,0x02,0x03,0x01,0x04,0x00,0x00,0x00}}, /* Locked/Unlocked */
{ 0x3D03, {0x06,0x0E,0x2B,0x34,0x01,0x01,0x01,0x05,0x04,0x02,0x03,0x01,0x01,0x01,0x00,0x00}}, /* Audio sampling rate */
@@ -648,7 +651,7 @@ static void mxf_write_mpegvideo_desc(AVFormatContext *s, AVStream *st)
AVRational dar;
int f1, f2;
- mxf_write_generic_desc(s, st, mxf_mpegvideo_descriptor_key, 153+sc->interlaced*4);
+ mxf_write_generic_desc(s, st, mxf_mpegvideo_descriptor_key, 169+sc->interlaced*4);
mxf_write_local_tag(pb, 4, 0x3203);
put_be32(pb, st->codec->width);
@@ -662,6 +665,14 @@ static void mxf_write_mpegvideo_desc(AVFormatContext *s, AVStream *st)
mxf_write_local_tag(pb, 4, 0x3208);
put_be32(pb, st->codec->height>>sc->interlaced);
+ // component depth
+ mxf_write_local_tag(pb, 4, 0x3301);
+ put_be32(pb, 8);
+
+ // horizontal subsampling
+ mxf_write_local_tag(pb, 4, 0x3302);
+ put_be32(pb, 2);
+
// bit rate
mxf_write_local_tag(pb, 4, 0x8000);
put_be32(pb, st->codec->bit_rate);