Opened 8 years ago

Last modified 8 years ago

#5086 new defect

Option 'analyzeduration' not respected when using concat demuxer

Reported by: David Banks Owned by:
Priority: normal Component: avformat
Version: unspecified Keywords: concat
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
When using the concat demuxer, the option -analyzeduration does not have any effect. This can cause some files to be incorrectly analyzed.

How to reproduce:
Compare the output of the following commands

amoe@motylyok $ ffmpeg -v 9 -loglevel 99 -analyzeduration 2147483647 -i file1.mkv bsfj.mkv
amoe@motylyok $ cat concat.lst
file 'file1.mkv'
amoe@motylyok $ ffmpeg -v 9 -loglevel 99 -analyzeduration 2147483647 -f concat -i  concat.lst bsfj.mkv
...
[matroska,webm @ 0x2e656e0] max_analyze_duration 5000000 reached at 5019000 microseconds
[matroska,webm @ 0x2e656e0] Could not find codec parameters for stream 0 (Video: h264, none(left), 496x360, 1/2000): unspecified pixel format
Consider increasing the value for the 'analyzeduration' and 'probesize' options
...

The first command analyzes the input file file1.mkv without problems, although only when using the analyzeduration option. However, specifying analyzeduration on the concat demuxer has no effect. I would hope that each file to be concatenated would be analyzed. For this demo it's only one file that's being concatenated so there is technically no point in using concat. In actuality though, I need to concatenate longer lists of files, but those that require a higher value for analyzeduration can't be used in these lists without causing broken output.

Attachments (4)

plain_demuxer_with_analyzeduration.log (3.1 KB ) - added by David Banks 8 years ago.
concat_demuxer_with_analyzeduration.log (52.5 KB ) - added by David Banks 8 years ago.
head-with-concat.log (54.1 KB ) - added by David Banks 8 years ago.
head-without-concat.log (3.5 KB ) - added by David Banks 8 years ago.

Download all attachments as: .zip

Change History (8)

by David Banks, 8 years ago

by David Banks, 8 years ago

comment:1 by Carl Eugen Hoyos, 8 years ago

Component: ffmpegavformat
Keywords: concat added

Please test current FFmpeg git head to make this a valid ticket.

by David Banks, 8 years ago

Attachment: head-with-concat.log added

by David Banks, 8 years ago

Attachment: head-without-concat.log added

in reply to:  1 comment:2 by David Banks, 8 years ago

Replying to cehoyos:

Please test current FFmpeg git head to make this a valid ticket.

Added new logs from git head.

comment:3 by Carl Eugen Hoyos, 8 years ago

Please provide your input sample.

comment:4 by Cigaes, 8 years ago

Sorry, no time to work on this for now. In case someone may want to:

The concat demuxer should not tray to make the analyzeduration option work, it is somewhat absurd. Instead, it should make it possible to set arbitrary options for each file and to make all the streams properties explicit, and the script should make sure that analyzeduration is not required on the virtual file.

Note: See TracTickets for help on using tickets.