diff options
Diffstat (limited to 'vp8/encoder/ratectrl.c')
-rw-r--r-- | vp8/encoder/ratectrl.c | 49 |
1 files changed, 47 insertions, 2 deletions
diff --git a/vp8/encoder/ratectrl.c b/vp8/encoder/ratectrl.c index e2c6327ef..9c3dcdb27 100644 --- a/vp8/encoder/ratectrl.c +++ b/vp8/encoder/ratectrl.c @@ -48,6 +48,7 @@ extern int inter_b_modes[10]; // Work in progress recalibration of baseline rate tables based on // the assumption that bits per mb is inversely proportional to the // quantizer value. +#if !CONFIG_EXTEND_QRANGE const int vp8_bits_per_mb[2][QINDEX_RANGE] = { // Intra case 450000/Qintra @@ -89,10 +90,54 @@ const int vp8_bits_per_mb[2][QINDEX_RANGE] = 11445, 11220, 11003, 10795, 10594, 10401, 10215, 10035, } }; +#else +const int vp8_bits_per_mb[2][QINDEX_RANGE] = +{ + // (Updated DEC 2010) Baseline estimate of Bits Per MB at each Q: + // 4500000/Qintra + { + 4500000,3600000,3000000,2571428,2250000,2000000,1800000,1636363, + 1500000,1384615,1285714,1200000,1125000,1058823,1000000, 947368, + 900000, 818181, 750000, 692307, 642857, 600000, 562500, 529411, + 500000, 473684, 450000, 428571, 409090, 391304, 375000, 352941, + 333333, 315789, 300000, 285714, 272727, 260869, 250000, 236842, + 225000, 214285, 204545, 195652, 187500, 180000, 171428, 163636, + 156521, 150000, 144000, 138461, 133333, 128571, 123287, 118421, + 113924, 109756, 105882, 102272, 98901, 95744, 92783, 90000, + 87378, 84905, 82568, 80357, 77586, 75000, 72580, 70312, + 68181, 66176, 64285, 62500, 60810, 59210, 57692, 56250, + 54545, 52941, 51428, 50000, 48648, 47368, 45918, 44554, + 43269, 42056, 40909, 39647, 38461, 37344, 36290, 35294, + 34351, 33333, 32374, 31468, 30612, 29801, 28938, 28125, + 27355, 26627, 25862, 25139, 24456, 23809, 23195, 22613, + 21951, 21327, 20737, 20179, 19650, 19067, 18518, 18000, + 17441, 16917, 16423, 15957, 15410, 14900, 14376, 13846, + }, + //2850000/Qinter + { + 2850000,2280000,1900000,1628571,1425000,1266666,1140000,1036363, + 950000, 876923, 814285, 760000, 712500, 670588, 633333, 600000, + 570000, 518181, 475000, 438461, 407142, 380000, 356250, 335294, + 316666, 300000, 285000, 271428, 259090, 247826, 237500, 223529, + 211111, 200000, 190000, 180952, 172727, 165217, 158333, 150000, + 142500, 135714, 129545, 123913, 118750, 114000, 108571, 103636, + 99130, 95000, 91200, 87692, 84444, 81428, 78082, 75000, + 72151, 69512, 67058, 64772, 62637, 60638, 58762, 57000, + 55339, 53773, 52293, 50892, 49137, 47500, 45967, 44531, + 43181, 41911, 40714, 39583, 38513, 37500, 36538, 35625, + 34545, 33529, 32571, 31666, 30810, 30000, 29081, 28217, + 27403, 26635, 25909, 25110, 24358, 23651, 22983, 22352, + 21755, 21111, 20503, 19930, 19387, 18874, 18327, 17812, + 17325, 16863, 16379, 15921, 15489, 15079, 14690, 14321, + 13902, 13507, 13133, 12780, 12445, 12076, 11728, 11400, + 11046, 10714, 10401, 10106, 9760, 9437, 9105, 8769, + } + }; + #endif static const int kf_boost_qadjustment[QINDEX_RANGE] = -{ - 128, 129, 130, 131, 132, 133, 134, 135, + { + 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, |