diff options
author | Deb Mukherjee <debargha@google.com> | 2014-04-01 17:31:59 -0700 |
---|---|---|
committer | Deb Mukherjee <debargha@google.com> | 2014-04-02 11:16:20 -0700 |
commit | 97f4fb7b5f1eb76d879601f469057f52a87b9f9c (patch) | |
tree | 5630520c7668e29e722ba1b0889e4be0f0327797 /vp9/encoder/vp9_ratectrl.c | |
parent | 8b8606a7374026d561a2c9596df772b5854e3654 (diff) | |
download | libvpx-97f4fb7b5f1eb76d879601f469057f52a87b9f9c.tar libvpx-97f4fb7b5f1eb76d879601f469057f52a87b9f9c.tar.gz libvpx-97f4fb7b5f1eb76d879601f469057f52a87b9f9c.tar.bz2 libvpx-97f4fb7b5f1eb76d879601f469057f52a87b9f9c.zip |
Rate ctrl changes to track target bitrates closer
Turns off the DISABLE_RC_LONG_TERM_MEM macro and makes other changes
in the way the bits are updated, to make 2-pass rate control track
target bitrates closer.
Change-Id: I5f3be4b11c2908e6a9a9a1dd4fcf4e65531c44d8
Diffstat (limited to 'vp9/encoder/vp9_ratectrl.c')
-rw-r--r-- | vp9/encoder/vp9_ratectrl.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/vp9/encoder/vp9_ratectrl.c b/vp9/encoder/vp9_ratectrl.c index 9ee58185c..016901456 100644 --- a/vp9/encoder/vp9_ratectrl.c +++ b/vp9/encoder/vp9_ratectrl.c @@ -1150,10 +1150,9 @@ void vp9_rc_postencode_update(VP9_COMP *cpi, uint64_t bytes_used) { // Actual bits spent rc->total_actual_bits += rc->projected_frame_size; + rc->total_target_bits += (cm->show_frame ? rc->av_per_frame_bandwidth : 0); - // Debug stats - rc->total_target_vs_actual += (rc->this_frame_target - - rc->projected_frame_size); + rc->total_target_vs_actual = rc->total_actual_bits - rc->total_target_bits; if (cpi->oxcf.play_alternate && cpi->refresh_alt_ref_frame && (cm->frame_type != KEY_FRAME)) |