[FFmpeg-devel] [PATCH 2/4] concatdec: factorize duration calculating code to get_duration function

Marton Balint cus at passwd.hu
Mon Nov 9 18:02:28 CET 2015

On Mon, 9 Nov 2015, Nicolas George wrote:

> Le duodi 12 brumaire, an CCXXIV, Marton Balint a écrit :
>> Signed-off-by: Marton Balint <cus at passwd.hu>
>> ---
>>  libavformat/concatdec.c | 19 ++++++++++++-------
>>  1 file changed, 12 insertions(+), 7 deletions(-)
> I do not object, but I find that this part of the code is starting to become
> quite convoluted. Are you sure it is really necessary. I understand that you
> want to use the duration for the metadata that will be later used in the
> select filter. Surely this information is only useful is the duration is
> reliable? So instead of changing this part, I suspect you could set the
> duration metadata only if the duration is already known, i.e. authoritative
> or reliable.

How do you know if it is reliable/authoritative? Is there a demuxer flag 
or something like that? Or you mean when the duration is explicitly set by 
the user or when inpoint and outpoint is both set, therefore the duration 
can be calculated?


More information about the ffmpeg-devel mailing list