[FFmpeg-devel] [PATCH 3/9] Only require first packet to be known for all audio and video streams
Michael Niedermayer
michaelni at gmx.at
Sat Sep 10 23:07:01 CEST 2011
On Sat, Sep 10, 2011 at 07:23:13PM +0200, Joakim Plate wrote:
> It can take a long time before subtitles or data streams show up,
> so we shouldn't wait for those before assuming we have all info
> for streams.
> ---
> libavformat/utils.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
> utils.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> b17c5b0b13cda175006e49f06565484f16f603e6 0003-Only-require-first-packet-to-be-known-for-all-audio-.patch
> diff --git a/libavformat/utils.c b/libavformat/utils.c
> index d08faea..dbe1a63 100644
> --- a/libavformat/utils.c
> +++ b/libavformat/utils.c
> @@ -2359,7 +2359,7 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
> break;
> if(st->parser && st->parser->parser->split && !st->codec->extradata)
> break;
> - if(st->first_dts == AV_NOPTS_VALUE)
> + if(st->first_dts == AV_NOPTS_VALUE && (st->codec->codec_type == AVMEDIA_TYPE_VIDEO || st->codec->codec_type == AVMEDIA_TYPE_AUDIO))
there are:
AVMEDIA_TYPE_UNKNOWN = -1,
AVMEDIA_TYPE_VIDEO,
AVMEDIA_TYPE_AUDIO,
AVMEDIA_TYPE_DATA,
AVMEDIA_TYPE_SUBTITLE,
AVMEDIA_TYPE_ATTACHMENT,
AVMEDIA_TYPE_NB
you argue for subtitles (and data) but this patch changes unknown and
attachment too
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
The bravest are surely those who have the clearest vision
of what is before them, glory and danger alike, and yet
notwithstanding go out to meet it. -- Thucydides
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20110910/f913dbdf/attachment.asc>
More information about the ffmpeg-devel
mailing list