On Sun,  5 Feb 2012 16:49:14 +0200, Andrey Utkin 
<[email protected]> wrote:
> I feel like there may be better place for these lines of code...
> ---8<---
> Set output files duration to recording_time option, if given.
> Rationale: to save duration into metadata for file that is written to
> non-seekable output, for formats like FLV (with metadata at beginning).
> ---
>  avconv.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/avconv.c b/avconv.c
> index 509b1dc..9861ade 100644
> --- a/avconv.c
> +++ b/avconv.c
> @@ -3942,6 +3942,8 @@ static void opt_output_file(void *optctx, const char 
> *filename)
>      output_files[nb_output_files - 1].ctx       = oc;
>      output_files[nb_output_files - 1].ost_index = nb_output_streams - 
> oc->nb_streams;
>      output_files[nb_output_files - 1].recording_time = o->recording_time;
> +    if (o->recording_time != INT64_MAX)
> +        oc->duration = o->recording_time;
>      output_files[nb_output_files - 1].start_time     = o->start_time;
>      output_files[nb_output_files - 1].limit_filesize = o->limit_filesize;
>      av_dict_copy(&output_files[nb_output_files - 1].opts, format_opts, 0);
> -- 
> 1.7.7
> 

Do any muxers actually use this value when set by the user?

-- 
Anton Khirnov
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to