diff options
author | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-10-21 12:18:45 +0000 |
---|---|---|
committer | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-10-21 12:18:45 +0000 |
commit | e95d9effa065c087455e17e95752e38eccc28d9a (patch) | |
tree | e64e720f9575489939ef35b7c0d725baac35b916 /libmpdemux | |
parent | 2255b29bfd3201ca12e33f756b7edf2fd191bbd2 (diff) |
AVI - no audio stream fix
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2331 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/aviheader.c | 2 | ||||
-rw-r--r-- | libmpdemux/aviheader.h | 1 | ||||
-rw-r--r-- | libmpdemux/demux_avi.c | 2 |
3 files changed, 4 insertions, 1 deletions
diff --git a/libmpdemux/aviheader.c b/libmpdemux/aviheader.c index a3c073185f..9cdbbda413 100644 --- a/libmpdemux/aviheader.c +++ b/libmpdemux/aviheader.c @@ -40,6 +40,7 @@ avi_priv_t* priv=demuxer->priv; //---- AVI header: priv->idx_size=0; +priv->audio_streams=0; while(1){ int id=stream_read_dword_le(demuxer->stream); int chunksize,size2; @@ -141,6 +142,7 @@ while(1){ } chunksize=0; if(verbose>=1) print_wave_header(sh_audio->wf); + ++priv->audio_streams; // if(demuxer->audio->id==-1) demuxer->audio->id=stream_id; } break; diff --git a/libmpdemux/aviheader.h b/libmpdemux/aviheader.h index d3d129b691..bb240419e7 100644 --- a/libmpdemux/aviheader.h +++ b/libmpdemux/aviheader.h @@ -95,6 +95,7 @@ typedef struct { int idx_offset; // ennyit kell hozzaadni az index offset ertekekhez // interleaved PTS stuff: int skip_video_frames; + int audio_streams; float avi_audio_pts; float avi_video_pts; float pts_correction; diff --git a/libmpdemux/demux_avi.c b/libmpdemux/demux_avi.c index 98e64d946d..9633f5868a 100644 --- a/libmpdemux/demux_avi.c +++ b/libmpdemux/demux_avi.c @@ -456,7 +456,7 @@ demuxer_t* demux_open_avi(demuxer_t* demuxer){ sh_video=d_video->sh;sh_video->ds=d_video; if(d_audio->id!=-2){ mp_msg(MSGT_DEMUX,MSGL_V,"AVI: Searching for audio stream (id:%d)\n",d_audio->id); - if(!ds_fill_buffer(d_audio)){ + if(!priv->audio_streams || !ds_fill_buffer(d_audio)){ mp_msg(MSGT_DEMUX,MSGL_INFO,"AVI: " MSGTR_MissingAudioStream); sh_audio=NULL; } else { |