ref: 6aca1d2d944bf0ac5810efd00e384847bd42eaee
parent: 57755aad5bdebfd5da9b2b3fc35dde1a2ddfee10
parent: 2eac6df788dbcfb8f9388f785e7b124765b252bc
author: Hui Su <huisu@google.com>
date: Wed Apr 25 12:25:40 EDT 2018
Merge "Add speed feture to control tx size search depth"
--- a/vp9/encoder/vp9_rdopt.c
+++ b/vp9/encoder/vp9_rdopt.c
@@ -859,7 +859,7 @@
if (cm->tx_mode == TX_MODE_SELECT) {
start_tx = max_tx_size;
- end_tx = 0;
+ end_tx = VPXMAX(start_tx - cpi->sf.tx_size_search_depth, 0);
} else {
TX_SIZE chosen_tx_size =
VPXMIN(max_tx_size, tx_mode_to_biggest_tx_size[cm->tx_mode]);
--- a/vp9/encoder/vp9_speed_features.c
+++ b/vp9/encoder/vp9_speed_features.c
@@ -817,6 +817,7 @@
// Some speed-up features even for best quality as minimal impact on quality.
sf->adaptive_rd_thresh = 1;
sf->tx_size_search_breakout = 1;
+ sf->tx_size_search_depth = 2;
sf->exhaustive_searches_thresh =
(cpi->twopass.fr_content_type == FC_GRAPHICS_ANIMATION) ? (1 << 20)
--- a/vp9/encoder/vp9_speed_features.h
+++ b/vp9/encoder/vp9_speed_features.h
@@ -272,6 +272,9 @@
// for intra and model coefs for the rest.
TX_SIZE_SEARCH_METHOD tx_size_search_method;
+ // How many levels of tx size to search, starting from the largest.
+ int tx_size_search_depth;
+
// Low precision 32x32 fdct keeps everything in 16 bits and thus is less
// precise but significantly faster than the non lp version.
int use_lp32x32fdct;