diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-01-15 18:51:04 +0400 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-01-15 18:51:14 +0400 |
commit | e074fe2962df5a43ac41f26b2180094057600cc5 (patch) | |
tree | 00fb58c9509ecf69dd7fa70c0aabca147dfb30bd /libavcodec/libx264.c | |
parent | 9aeffb3c2a0d86a1271836f87915d3a2e069cdd2 (diff) | |
parent | 47812070a267cbdf74164e154d03d99bf8ced100 (diff) |
Merge commit '47812070a267cbdf74164e154d03d99bf8ced100'
* commit '47812070a267cbdf74164e154d03d99bf8ced100':
libx264: use the library specific default rc_initial_buffer_occupancy
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/libx264.c')
-rw-r--r-- | libavcodec/libx264.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c index 8765e56d02..e2ef7530a6 100644 --- a/libavcodec/libx264.c +++ b/libavcodec/libx264.c @@ -335,7 +335,7 @@ static av_cold int X264_init(AVCodecContext *avctx) x4->params.rc.f_rf_constant_max = x4->crf_max; } - if (avctx->rc_buffer_size && avctx->rc_initial_buffer_occupancy && + if (avctx->rc_buffer_size && avctx->rc_initial_buffer_occupancy > 0 && (avctx->rc_initial_buffer_occupancy <= avctx->rc_buffer_size)) { x4->params.rc.f_vbv_buffer_init = (float)avctx->rc_initial_buffer_occupancy / avctx->rc_buffer_size; @@ -695,6 +695,7 @@ static const AVCodecDefault x264_defaults[] = { { "threads", AV_STRINGIFY(X264_THREADS_AUTO) }, { "thread_type", "0" }, { "flags", "+cgop" }, + { "rc_init_occupancy","-1" }, { NULL }, }; |