diff options
author | jackychen <jackychen@google.com> | 2016-06-23 09:40:49 -0700 |
---|---|---|
committer | jackychen <jackychen@google.com> | 2016-06-27 14:44:27 -0700 |
commit | 8cbd4f87011efff05efab2fd99c18abd5baaaa2a (patch) | |
tree | 4e31fe7b3ff75e7a355d1ac8edb4d054d049214e /vp9/encoder/vp9_encodeframe.c | |
parent | 71aacf39c7531802143fa127141584774d5c2433 (diff) | |
download | libvpx-8cbd4f87011efff05efab2fd99c18abd5baaaa2a.tar libvpx-8cbd4f87011efff05efab2fd99c18abd5baaaa2a.tar.gz libvpx-8cbd4f87011efff05efab2fd99c18abd5baaaa2a.tar.bz2 libvpx-8cbd4f87011efff05efab2fd99c18abd5baaaa2a.zip |
vp9: Increase thr_var for 32x32 blocks in var-based partitioning.
For real-time mode, increase variance threshold for 32x32 blocks in
var-based partitioning for resolution >= 720p, so that it is more
likely to stay at 32x32 for high resolution which accelerates the
encoding speed with little/no PSNR drop.
PSNR effect on different speed settings:
speed 8 rtc: 0.02 overall PSNR drop, 0.285% SSIM drop
speed 7 rtc: 0.196% overall PSNR increase, 0.066% SSIM increase
speed 5 rtc_derf: no effect.
Speed up:
gips_motion_WHD, 1mbps: 2.5% faster on speed 7, 2.6% faster on speed8
gips_stat_WHD, 1mbps: 4.6% faster on speed 7, 5.6% faster on speed8
Change-Id: Ie7c33c4d2dd7d09294917e031357fc5476c3a4bb
Diffstat (limited to 'vp9/encoder/vp9_encodeframe.c')
-rw-r--r-- | vp9/encoder/vp9_encodeframe.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c index f66ed9ed3..50e11948f 100644 --- a/vp9/encoder/vp9_encodeframe.c +++ b/vp9/encoder/vp9_encodeframe.c @@ -503,16 +503,18 @@ static void set_vbp_thresholds(VP9_COMP *cpi, int64_t thresholds[], int q) { else if (noise_level < kLow) threshold_base = (7 * threshold_base) >> 3; } + thresholds[0] = threshold_base; + thresholds[2] = threshold_base << cpi->oxcf.speed; if (cm->width <= 352 && cm->height <= 288) { thresholds[0] = threshold_base >> 3; thresholds[1] = threshold_base >> 1; thresholds[2] = threshold_base << 3; - } else { - thresholds[0] = threshold_base; + } else if (cm->width < 1280 && cm->height < 720) { thresholds[1] = (5 * threshold_base) >> 2; - if (cm->width >= 1920 && cm->height >= 1080) - thresholds[1] = (7 * threshold_base) >> 2; - thresholds[2] = threshold_base << cpi->oxcf.speed; + } else if (cm->width < 1920 && cm->height < 1080) { + thresholds[1] = threshold_base << 1; + } else { + thresholds[1] = (5 * threshold_base) >> 1; } } } |