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
This commit is contained in:
Deb Mukherjee
2014-04-01 17:31:59 -07:00
parent 8b8606a737
commit 97f4fb7b5f
8 changed files with 30 additions and 47 deletions

View File

@@ -1186,7 +1186,7 @@ static size_t write_compressed_header(VP9_COMP *cpi, uint8_t *data) {
void vp9_pack_bitstream(VP9_COMP *cpi, uint8_t *dest, size_t *size) {
uint8_t *data = dest;
size_t first_part_size;
size_t first_part_size, uncompressed_hdr_size;
struct vp9_write_bit_buffer wb = {data, 0};
struct vp9_write_bit_buffer saved_wb;
@@ -1194,7 +1194,8 @@ void vp9_pack_bitstream(VP9_COMP *cpi, uint8_t *dest, size_t *size) {
saved_wb = wb;
vp9_wb_write_literal(&wb, 0, 16); // don't know in advance first part. size
data += vp9_rb_bytes_written(&wb);
uncompressed_hdr_size = vp9_rb_bytes_written(&wb);
data += uncompressed_hdr_size;
vp9_compute_update_table();