On Sat, Sep 03, 2011 at 10:16:42PM +0200, Anton Khirnov wrote:
> ---
> avconv.c | 17 +++++++++--------
> 1 files changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/avconv.c b/avconv.c
> index 6f0813d..a985297 100644
> --- a/avconv.c
> +++ b/avconv.c
> @@ -140,9 +140,6 @@ static unsigned int subtitle_codec_tag = 0;
> static int data_disable = 0;
> static unsigned int data_codec_tag = 0;
>
> -static float mux_preload= 0.5;
> -static float mux_max_delay= 0.7;
> -
> static int file_overwrite = 0;
> static int do_benchmark = 0;
> static int do_hex_dump = 0;
> @@ -319,6 +316,8 @@ typedef struct OptionsContext {
>
> int64_t recording_time;
> uint64_t limit_filesize;
> + float mux_preload;
> + float mux_max_delay;
>
> SpecifierOpt *metadata;
> int nb_metadata;
> @@ -368,6 +367,8 @@ static void reset_options(OptionsContext *o)
>
> memset(o, 0, sizeof(*o));
>
> + o->mux_preload = 0.5;
> + o->mux_max_delay = 0.7;
> o->recording_time = INT64_MAX;
> o->limit_filesize = UINT64_MAX;
> o->chapters_input_file = INT_MAX;
> @@ -3569,8 +3570,8 @@ static void opt_output_file(void *optctx, const char
> *filename)
> }
> }
>
> - oc->preload= (int)(mux_preload*AV_TIME_BASE);
> - oc->max_delay= (int)(mux_max_delay*AV_TIME_BASE);
> + oc->preload = (int)(o->mux_preload*AV_TIME_BASE);
> + oc->max_delay = (int)(o->mux_max_delay*AV_TIME_BASE);
> oc->flags |= AVFMT_FLAG_NONBLOCK;
>
> /* copy chapters */
> @@ -3935,7 +3936,7 @@ static int opt_target(OptionsContext *o, const char
> *opt, const char *arg)
> and the first pack from the other stream, respectively, may also
> have
> been written before.
> So the real data starts at SCR 36000+3*1200. */
> - mux_preload= (36000+3*1200) / 90000.0; //0.44
> + o->mux_preload = (36000+3*1200) / 90000.0; //0.44
> } else if(!strcmp(arg, "svcd")) {
Could you also please some spaces around operators while you're at it. But the
patch okay as is.
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel