diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-01-15 01:07:00 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-01-15 01:16:54 +0100 |
commit | 4640da7e58509996ff03b1a0b018ca8f337391c7 (patch) | |
tree | 732195f8bc4987e4974df716789044c7e3db0836 /libavcodec/libx264.c | |
parent | a91f2066651416e0f9315e7fb0132587352c75dc (diff) | |
parent | 4cd0bdae9a62d1f0366e60603222762af31e5289 (diff) | |
download | ffmpeg-4640da7e58509996ff03b1a0b018ca8f337391c7.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
sgidec: Use bytestream2 functions to prevent buffer overreads.
cosmetics: Move static and inline attributes to more standard places.
configure: provide libavfilter/version.h header to get_version()
swscale: change yuv2yuvX code to use cpuflag().
libx264: Don't leave max_b_frames as -1 if the user didn't set it
FATE: convert output to rgba for the targa tests which currently output pal8
fate: add missing reference files for targa tests in 9c2f9b0e2
FATE: enable the 2 remaining targa conformance suite tests
targa: add support for rgb555 palette
FATE: fix targa tests on big-endian systems
Conflicts:
libavcodec/sgidec.c
libavcodec/targa.c
libswscale/x86/output.asm
tests/fate/image.mak
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/libx264.c')
-rw-r--r-- | libavcodec/libx264.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c index f23b3fa9ae..59257f0199 100644 --- a/libavcodec/libx264.c +++ b/libavcodec/libx264.c @@ -532,6 +532,9 @@ static av_cold int X264_init(AVCodecContext *avctx) // update AVCodecContext with x264 parameters avctx->has_b_frames = x4->params.i_bframe ? x4->params.i_bframe_pyramid ? 2 : 1 : 0; + if (avctx->max_b_frames < 0) + avctx->max_b_frames = 0; + avctx->bit_rate = x4->params.rc.i_bitrate*1000; #if FF_API_X264_GLOBAL_OPTS avctx->crf = x4->params.rc.f_rf_constant; |