Mercurial > mplayer.hg
changeset 26088:12904c37c798
Don't select subtitle track in lavf and mkv demuxers.
author | eugeni |
---|---|
date | Fri, 29 Feb 2008 17:25:47 +0000 |
parents | 2a112aed0dda |
children | e2f35d90ad39 |
files | libmpdemux/demux_lavf.c libmpdemux/demux_mkv.c libmpdemux/demuxer.c |
diffstat | 3 files changed, 0 insertions(+), 32 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_lavf.c Fri Feb 29 17:25:44 2008 +0000 +++ b/libmpdemux/demux_lavf.c Fri Feb 29 17:25:47 2008 +0000 @@ -433,13 +433,6 @@ } if (st->language) sh_sub->lang = strdup(st->language); - if (demuxer->sub->id == -1 - || (demuxer->sub->id == -2 && (dvdsub_lang && st->language[0] && !strncmp(dvdsub_lang, st->language, 3))) - || demuxer->sub->id == priv->sub_streams) { - dvdsub_id = priv->sub_streams; - demuxer->sub->id = priv->sub_streams; - demuxer->sub->sh = sh_sub; - } priv->sub_streams++; break; }
--- a/libmpdemux/demux_mkv.c Fri Feb 29 17:25:44 2008 +0000 +++ b/libmpdemux/demux_mkv.c Fri Feb 29 17:25:47 2008 +0000 @@ -2475,27 +2475,6 @@ demux_mkv_parse_vobsub_data (demuxer); - /* DO NOT automatically select a subtitle track and behave like DVD */ - /* playback: only show subtitles if the user explicitely wants them. */ - track = NULL; - if (demuxer->sub->id >= 0) - track = demux_mkv_find_track_by_num (mkv_d, demuxer->sub->id, - MATROSKA_TRACK_SUBTITLE); - else if (dvdsub_lang != NULL) - track = demux_mkv_find_track_by_language (mkv_d, dvdsub_lang, - MATROSKA_TRACK_SUBTITLE); - - if (track) - { - mp_msg (MSGT_DEMUX, MSGL_INFO, - MSGTR_MPDEMUX_MKV_WillDisplaySubtitleTrack, track->tnum); - dvdsub_id = demux_mkv_reverse_id(mkv_d, track->tnum, MATROSKA_TRACK_SUBTITLE); - demuxer->sub->id = track->tnum; - demuxer->sub->sh = demuxer->s_streams[track->tnum]; - } - else - demuxer->sub->id = -2; - if (demuxer->chapters) { for (i=0; i < (int)demuxer->num_chapters; i++)
--- a/libmpdemux/demuxer.c Fri Feb 29 17:25:44 2008 +0000 +++ b/libmpdemux/demuxer.c Fri Feb 29 17:25:47 2008 +0000 @@ -241,10 +241,6 @@ demuxer->s_streams[id] = sh; sh->sid = sid; mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_SUBTITLE_ID=%d\n", sid); - if (dvdsub_id == id) { - demuxer->sub->id = id; - demuxer->sub->sh = sh; - } } return demuxer->s_streams[id]; }