--- mplayer/libmpdemux/demux_ts.c.speedupTs~ 2007-06-10 18:44:27.000000000 +0000 +++ mplayer/libmpdemux/demux_ts.c 2007-06-10 19:16:32.000000000 +0000 @@ -642,7 +642,7 @@ init_pos = stream_tell(demuxer->stream); mp_msg(MSGT_DEMUXER, MSGL_V, "PROBING UP TO %"PRIu64", PROG: %d\n", (uint64_t) param->probe, param->prog); end_pos = init_pos + (param->probe ? param->probe : TS_MAX_PROBE_SIZE); - while(1) + while(!video_found || !audio_found) { pos = stream_tell(demuxer->stream); if(pos > end_pos || demuxer->stream->eof) @@ -782,6 +782,7 @@ { //novideo or we have at least 348 audio packets (64 KB) without video (TS with audio only) param->vtype = 0; + video_found = 1; break; } @@ -813,6 +814,9 @@ } } + if((param->vtype == 0) && video_found) + video_found = 0; + for(i=0; i<8192; i++) { if(pes_priv1[i].buf != NULL)