[MPlayer-users] 2 bugs in cvs

Nico nsabbi at libero.it
Sat Apr 12 21:26:21 CEST 2003



Vladimir Mosgalin wrote:
> [Automatic answer: RTFM (read DOCS, FAQ), also read DOCS/bugreports.html]
> Well, I understand that mplayer in cvs is very unstable and so on... But
> these bugs are not present in 0.90, something from later additions broke
> them, maybe someone will fix it by hot traces...
> 
> First is TS mpeg handling. I've got mpeg file that mplayer 0.90 played
> fine, saying that this is MPEG PES file, but current version says that
> this is TS and than hangs trying to parse headers... Unfortunately, I
> will not be able to upload this file for some days, but I can send it by
> mail - 15k piece shows this bug. Here is mplayer -v output anyway.


Hi,
you are right, that misdetection can happen because TS is a real beast 
with few means to detect if a stream is a real TS or not, so our demuxer 
must be very flexible :) .
I won't you send a patch because there's another one being revised by 
smeone else that should hopefully be applied soon :), so at the moment 
you can fix your mplayer-cvs applying this modifications:

in function ts_detect_stream change

if(ts_parse(demuxer, &es, tmp))
with
if(ts_parse(demuxer, &es, tmp, 1))

then change the definition of ts_parse:

int ts_parse(demuxer_t * demuxer , ES_stream_t *es, unsigned char packet)

with

int ts_parse(demuxer_t * demuxer , ES_stream_t *es, unsigned char 
*packet, int strict_cc)


and in the same function change

if(! cc_ok)
           {
             mp_msg(MSGT_DEMUX, MSGL_DBG2, "ts_parse: CC-Check NOT OK: 
%d -> %d\n", tss->last_cc, cc);

           }

with


if(! cc_ok)
           {
             mp_msg(MSGT_DEMUX, MSGL_DBG2, "ts_parse: CC-Check NOT OK: 
%d -> %d\n", tss->last_cc, cc);
                 if(strict_cc)
		       return 0;
           }



and in function demux_ts_fill_buffer change

while(len = ts_parse(demuxer, &es, packet))

with

while(len = ts_parse(demuxer, &es, packet, 0))

Additionally, at the top of the file,  you had better increase

#define NUM_CONSECUTIVE_TS_PACKETS 5

with

#define NUM_CONSECUTIVE_TS_PACKETS 10

(or something larger).


Please, let me know if it fixes your problem.

Thanks,
				Nico



More information about the MPlayer-users mailing list