Commit f129e095 authored by Jerome Jiang's avatar Jerome Jiang

vp9: Turn on the partition copy for speed 8. Tune threshold.

For speed 8, it speeds up the encoding on android by 6% for QVGA and
7.4% for VGA with the new threshold. Overall PSNR is improved by 0.667
for rtc.

Change-Id: I4a644560b32c0b5b4e9f49ffb953d000413a3732
parent 91fc730d
......@@ -516,6 +516,7 @@ void vp9_set_variance_partition_thresholds(VP9_COMP *cpi, int q) {
// The thresholds below are not changed locally.
if (is_key_frame) {
cpi->vbp_threshold_sad = 0;
cpi->vbp_threshold_copy = 0;
cpi->vbp_bsize_min = BLOCK_8X8;
} else {
if (cm->width <= 352 && cm->height <= 288)
......@@ -525,8 +526,13 @@ void vp9_set_variance_partition_thresholds(VP9_COMP *cpi, int q) {
? (cpi->y_dequant[q][1] << 1)
: 1000;
cpi->vbp_bsize_min = BLOCK_16X16;
if (cm->width <= 352 && cm->height <= 288)
cpi->vbp_threshold_copy = 40960;
else
cpi->vbp_threshold_copy = (cpi->y_dequant[q][1] << 6) > 32000
? (cpi->y_dequant[q][1] << 6)
: 32000;
}
cpi->vbp_threshold_copy = cpi->vbp_thresholds[0] << 16;
cpi->vbp_threshold_minmax = 15 + (q >> 3);
}
}
......
......@@ -497,8 +497,10 @@ static void set_rt_speed_feature(VP9_COMP *cpi, SPEED_FEATURES *sf, int speed,
if (speed >= 8) {
sf->adaptive_rd_thresh = 4;
// Disabled for now until the threshold is tuned.
sf->copy_partition_flag = 0;
// Enable partition copy
if (!cpi->use_svc && !cpi->resize_pending && !cpi->resize_state &&
!cpi->external_resize)
sf->copy_partition_flag = 1;
if (sf->copy_partition_flag) {
if (cpi->prev_partition == NULL) {
cpi->prev_partition = (BLOCK_SIZE *)vpx_calloc(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment