Mercurial > mplayer.hg
changeset 29615:70404a7bebaf
Always register all streams from libavformat, not just those belonging to a program.
author | reimar |
---|---|
date | Tue, 08 Sep 2009 08:55:05 +0000 |
parents | 1e19b831575b |
children | 2609ee836bc1 |
files | libmpdemux/demux_lavf.c |
diffstat | 1 files changed, 3 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_lavf.c Tue Sep 08 08:50:03 2009 +0000 +++ b/libmpdemux/demux_lavf.c Tue Sep 08 08:55:05 2009 +0000 @@ -491,6 +491,8 @@ demuxer_add_chapter(demuxer, t ? t->value : NULL, start, end); } + for(i=0; i<avfc->nb_streams; i++) + handle_stream(demuxer, avfc, i); if(avfc->nb_programs) { int p, start=0, found=0; @@ -512,15 +514,11 @@ AVProgram *program = avfc->programs[p]; t = av_metadata_get(program->metadata, "title", NULL, 0); mp_msg(MSGT_HEADER,MSGL_INFO,"LAVF: Program %d %s\n", program->id, t ? t->value : ""); - for(i=0; i<program->nb_stream_indexes; i++) - handle_stream(demuxer, avfc, program->stream_index[i]); if(!priv->cur_program && (demuxer->video->sh || demuxer->audio->sh)) priv->cur_program = program->id; p = (p + 1) % avfc->nb_programs; } while(p!=start); - } else - for(i=0; i<avfc->nb_streams; i++) - handle_stream(demuxer, avfc, i); + } mp_msg(MSGT_HEADER,MSGL_V,"LAVF: %d audio and %d video streams found\n",priv->audio_streams,priv->video_streams); mp_msg(MSGT_HEADER,MSGL_V,"LAVF: build %d\n", LIBAVFORMAT_BUILD);