ref: e4dfacbf6c362aec84d2fdeb3de04d676b5ec176
parent: 2eac6df788dbcfb8f9388f785e7b124765b252bc
author: Hui Su <huisu@google.com>
date: Tue Apr 24 18:42:54 EDT 2018
Do one level less of transform search for large blocks If block size is larger than 32x32, search transform size for one level less than the other blocks. This mainly affects speed 0 and 1, as speed >= 2 uses largest transform size(except for keyframes and alt-ref frames). Compression(negative means gain): speed 0 speed 1 lowres -0.007% 0.00% midres 0.023% -0.011% hdres 0.002% -0.016% Encoder speed: Tested on crowd_run_1080p 30 frames Fixed QP = 30, speed 0: 582.5s -> 564.6s speed 1: 75.0s -> 73.3s Change-Id: I46622efafe0e88d502efa1480a5324ead1d1e8d0
--- a/vp9/encoder/vp9_rdopt.c
+++ b/vp9/encoder/vp9_rdopt.c
@@ -859,6 +859,7 @@
if (cm->tx_mode == TX_MODE_SELECT) {
start_tx = max_tx_size;
end_tx = VPXMAX(start_tx - cpi->sf.tx_size_search_depth, 0);
+ if (bs > BLOCK_32X32) end_tx = VPXMIN(end_tx + 1, start_tx);
} else {
TX_SIZE chosen_tx_size =
VPXMIN(max_tx_size, tx_mode_to_biggest_tx_size[cm->tx_mode]);