diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-06-24 07:49:04 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-06-24 07:49:04 +0000 |
commit | 00be4423dadbece2f9682cef9aa3f0327fc4df53 (patch) | |
tree | c716c24cfb2caa55fca441cc2bce9c56e7ee319f /libmpdemux | |
parent | f29dc82d7e13acd8e483c0197cafb0e0dff0b38e (diff) |
Print ID_AID_???_LANG and ID_SID_???_LANG in lavf demuxer so that frontends
can correctly display the languages of audio and subtitle tracks.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29383 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/demux_lavf.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/libmpdemux/demux_lavf.c b/libmpdemux/demux_lavf.c index 8e94acc2ca..9f16233d4b 100644 --- a/libmpdemux/demux_lavf.c +++ b/libmpdemux/demux_lavf.c @@ -291,8 +291,10 @@ static void handle_stream(demuxer_t *demuxer, AVFormatContext *avfc, int i) { sh_audio->format = 0x7; break; } - if (st->language) + if (st->language) { sh_audio->lang = strdup(st->language); + mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_AID_%d_LANG=%s\n", i, sh_audio->lang); + } if (st->disposition & AV_DISPOSITION_DEFAULT) sh_audio->default_track = 1; if(mp_msg_test(MSGT_HEADER,MSGL_V) ) print_wave_header(sh_audio->wf, MSGL_V); @@ -399,8 +401,10 @@ static void handle_stream(demuxer_t *demuxer, AVFormatContext *avfc, int i) { memcpy(sh_sub->extradata, codec->extradata, codec->extradata_size); sh_sub->extradata_len = codec->extradata_size; } - if (st->language) + if (st->language) { sh_sub->lang = strdup(st->language); + mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_SID_%d_LANG=%s\n", priv->sub_streams, sh_sub->lang); + } if (st->disposition & AV_DISPOSITION_DEFAULT) sh_sub->default_track = 1; priv->sub_streams++; |