[FFmpeg-devel] [PATCH] Dump info for all streams (not just those known to be in a program)

Wolfram Gloger wmglo
Sat Nov 10 16:56:31 CET 2007


Hi,

> That's not the point.  Even if you've never seen it go wrong, it's
> still guesswork, and guessing has no place in FFmpeg.

Ok, I've checked again, the 'guessing' we're talking about is:

                if (pes->header[0] == 0x00 && pes->header[1] == 0x00 &&
                    pes->header[2] == 0x01) {
                    /* it must be an mpeg2 PES stream */
                    code = pes->header[3] | 0x100;
                    if (!((code >= 0x1c0 && code <= 0x1df) ||
                          (code >= 0x1e0 && code <= 0x1ef) ||
                          (code == 0x1bd) || (code == 0x1fd)))
                        goto skip;

I can't see that going wrong, at least no more than e.g. our probe
functions for mpeg streams can go wrong.  Are you suggesting to
remove mpegps_probe() as well?
[BTW shouldn't mpegps_probe() be exported and used in that place in
 mpegts.c to remove duplication?]

> > Sorry, I think that's awkward and not at all user friendly.
> 
> It's not user friendly to create unplayable files.

I can't see how that could happen.

I also see my patch fixing a more generic issue.  There could be a
format that does have a notion of "programs" but where not all streams
are part of a "program".

Regards,
Wolfram.




More information about the ffmpeg-devel mailing list