[x264-devel] Re: x264 improvement
Andrea Barbieri
andrea.barbieri at movingimageresearch.com
Fri Mar 10 13:47:50 CET 2006
Hello,
I have attached two patch files of the MSU start_qp proposed change...
best regards
andrea
--
Andrea Barbieri
KeyID=0x034DFD5A
KeyFingerprint=C1 68 EA 9A 71 89 53 8D 21 4F 12 81 A7 52 9F 32 03 4D FD 5A
Moving Image Research, The Workshop, Hampton Lane, Bristol, BS6 6LE, UK
Tel +44 117 9732200, FAX +44 117 9732210
http://www.movingimageresearch.com/
-------------- next part --------------
*** x264/x264.h Mon Mar 6 10:03:52 2006
--- x264_new/x264.h Fri Mar 10 12:24:14 2006
***************
*** 215,220 ****
--- 215,221 ----
int i_qp_min; /* min allowed QP value */
int i_qp_max; /* max allowed QP value */
int i_qp_step; /* max QP step between frames */
+ int i_qp_start;
int b_cbr; /* use bitrate instead of CQP */
int i_bitrate;
-------------- next part --------------
*** x264/encoder/ratecontrol.c Fri Mar 10 10:19:25 2006
--- x264_new/encoder/ratecontrol.c Fri Mar 10 12:27:54 2006
***************
*** 254,262 ****
if( rc->b_abr )
{
/* FIXME shouldn't need to arbitrarily specify a QP,
* but this is more robust than BPP measures */
! #define ABR_INIT_QP ( h->param.rc.i_rf_constant > 0 ? h->param.rc.i_rf_constant : 24 )
rc->accum_p_norm = .01;
rc->accum_p_qp = ABR_INIT_QP * rc->accum_p_norm;
rc->cplxr_sum = .01;
--- 254,263 ----
if( rc->b_abr )
{
+ h->param.rc.i_qp_start = (int) (-0.287 * exp ( 0.501 * log ( h->param.rc.i_bitrate ) ) + 39.148);
/* FIXME shouldn't need to arbitrarily specify a QP,
* but this is more robust than BPP measures */
! #define ABR_INIT_QP ( h->param.rc.i_rf_constant > 0 ? h->param.rc.i_rf_constant : h->param.rc.i_qp_start )
rc->accum_p_norm = .01;
rc->accum_p_qp = ABR_INIT_QP * rc->accum_p_norm;
rc->cplxr_sum = .01;
More information about the x264-devel
mailing list