diff options
author | Anton Khirnov <anton@khirnov.net> | 2011-10-09 15:04:38 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2011-10-25 16:27:48 +0200 |
commit | f172132f825cec4e446a5bdde4ffa9065ba9061f (patch) | |
tree | 96839afb55479392166d12cc205dc825eb49ec34 /avconv.c | |
parent | 28287045ca3ee34e4ea980628ec8314fd2d819ae (diff) | |
download | ffmpeg-f172132f825cec4e446a5bdde4ffa9065ba9061f.tar.gz |
mpegenc: add preload private option.
Deprecate AVFormatContext.preload.
Diffstat (limited to 'avconv.c')
-rw-r--r-- | avconv.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -375,7 +375,6 @@ 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; @@ -3572,7 +3571,11 @@ static void opt_output_file(void *optctx, const char *filename) } } - oc->preload = (int)(o->mux_preload * AV_TIME_BASE); + if (o->mux_preload) { + uint8_t buf[64]; + snprintf(buf, sizeof(buf), "%d", (int)(o->mux_preload*AV_TIME_BASE)); + av_dict_set(&output_files[nb_output_files - 1].opts, "preload", buf, 0); + } oc->max_delay = (int)(o->mux_max_delay * AV_TIME_BASE); oc->flags |= AVFMT_FLAG_NONBLOCK; |