[vlc-devel] commit: set rc_method = X264_RC_CQP if qp is set (Ilkka Ollakka )
git version control
git at videolan.org
Thu Mar 20 17:01:45 CET 2008
vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Thu Mar 20 18:01:00 2008 +0200| [951c16c72039c9ef696fdd237d6d0304c5df3665]
set rc_method = X264_RC_CQP if qp is set
set qpmin/qpmax even without qp set.
more constant on x264 parameters handling.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=951c16c72039c9ef696fdd237d6d0304c5df3665
---
modules/codec/x264.c | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/modules/codec/x264.c b/modules/codec/x264.c
index ff4ec0c..cdc84a7 100644
--- a/modules/codec/x264.c
+++ b/modules/codec/x264.c
@@ -771,9 +771,17 @@ static int Open ( vlc_object_t *p_this )
var_Get( p_enc, SOUT_CFG_PREFIX "qpstep", &val );
if( val.i_int >= 0 && val.i_int <= 51 ) p_sys->param.rc.i_qp_step = val.i_int;
var_Get( p_enc, SOUT_CFG_PREFIX "qpmin", &val );
- if( val.i_int >= 0 && val.i_int <= 51 ) i_qmin = val.i_int;
+ if( val.i_int >= 0 && val.i_int <= 51 )
+ {
+ i_qmin = val.i_int;
+ p_sys->param.rc.i_qp_min = i_qmin;
+ }
var_Get( p_enc, SOUT_CFG_PREFIX "qpmax", &val );
- if( val.i_int >= 0 && val.i_int <= 51 ) i_qmax = val.i_int;
+ if( val.i_int >= 0 && val.i_int <= 51 )
+ {
+ i_qmax = val.i_int;
+ p_sys->param.rc.i_qp_max = i_qmax;
+ }
var_Get( p_enc, SOUT_CFG_PREFIX "qp", &val );
if( val.i_int >= 0 && val.i_int <= 51 )
@@ -781,6 +789,7 @@ static int Open ( vlc_object_t *p_this )
if( i_qmin > val.i_int ) i_qmin = val.i_int;
if( i_qmax < val.i_int ) i_qmax = val.i_int;
+ p_sys->param.rc.i_rc_method = X264_RC_CQP;
#if X264_BUILD >= 0x000a
p_sys->param.rc.i_qp_constant = val.i_int;
p_sys->param.rc.i_qp_min = i_qmin;
More information about the vlc-devel
mailing list