diff libx264.c @ 11689:2312dfbe9251 libavcodec

Add intra refresh and crf-max support to the libavcodec libx264 wrapper. Minor version bump.
author darkshikari
date Thu, 06 May 2010 22:38:18 +0000
parents 52bc4e605761
children 40911dc14bdc
line wrap: on
line diff
--- a/libx264.c	Thu May 06 20:38:42 2010 +0000
+++ b/libx264.c	Thu May 06 22:38:18 2010 +0000
@@ -156,6 +156,7 @@
     x4->params.p_log_private        = avctx;
 
     x4->params.i_keyint_max         = avctx->gop_size;
+    x4->params.b_intra_refresh      = avctx->flags2 & CODEC_FLAG2_INTRA_REFRESH;
     x4->params.rc.i_bitrate         = avctx->bit_rate       / 1000;
     x4->params.rc.i_vbv_buffer_size = avctx->rc_buffer_size / 1000;
     x4->params.rc.i_vbv_max_bitrate = avctx->rc_max_rate    / 1000;
@@ -166,6 +167,7 @@
         if (avctx->crf) {
             x4->params.rc.i_rc_method   = X264_RC_CRF;
             x4->params.rc.f_rf_constant = avctx->crf;
+            x4->params.rc.f_rf_constant_max = avctx->crf_max;
         } else if (avctx->cqp > -1) {
             x4->params.rc.i_rc_method   = X264_RC_CQP;
             x4->params.rc.i_qp_constant = avctx->cqp;