diff options
author | Anssi Hannula <anssi.hannula@iki.fi> | 2011-02-14 21:55:04 +0300 |
---|---|---|
committer | Mans Rullgard <mans@mansr.com> | 2011-02-15 02:18:26 +0300 |
commit | 60e7306643054e93dfc1962f89b24554bb76e18a (patch) | |
tree | ef213c3b3a786fe75b51a002fbd62c95b0357f3f /libavformat/mpegts.c | |
parent | 935ee1b9bba3d2fa1bf0d48eef278956307478cb (diff) |
mpegts: set st->disposition according to ISO 639 language descriptor
Signed-off-by: Mans Rullgard <mans@mansr.com>
Diffstat (limited to 'libavformat/mpegts.c')
-rw-r--r-- | libavformat/mpegts.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c index e8d82ac21c..abb6f080f4 100644 --- a/libavformat/mpegts.c +++ b/libavformat/mpegts.c @@ -954,6 +954,11 @@ int ff_parse_mpeg2_descriptor(AVFormatContext *fc, AVStream *st, int stream_type language[2] = get8(pp, desc_end); language[3] = 0; av_metadata_set2(&st->metadata, "language", language, 0); + switch (get8(pp, desc_end)) { + case 0x01: st->disposition |= AV_DISPOSITION_CLEAN_EFFECTS; break; + case 0x02: st->disposition |= AV_DISPOSITION_HEARING_IMPAIRED; break; + case 0x03: st->disposition |= AV_DISPOSITION_VISUAL_IMPAIRED; break; + } break; case 0x05: /* registration descriptor */ st->codec->codec_tag = bytestream_get_le32(pp); |