Disable trskip SAD calcultation when trskip is not enabled.

This commit is contained in:
Ari Koivula 2015-06-03 15:04:40 +03:00 committed by Marko Viitanen
parent 3253ba4812
commit 30f8640380

View file

@ -1891,7 +1891,7 @@ static double get_cost(encoder_state_t * const state,
int width) int width)
{ {
double satd_cost = satd_func(pred, orig_block); double satd_cost = satd_func(pred, orig_block);
if (TRSKIP_RATIO != 0 && width == 4) { if (TRSKIP_RATIO != 0 && width == 4 && state->encoder_control->trskip_enable) {
// If the mode looks better with SAD than SATD it might be a good // If the mode looks better with SAD than SATD it might be a good
// candidate for transform skip. How much better SAD has to be is // candidate for transform skip. How much better SAD has to be is
// controlled by TRSKIP_RATIO. // controlled by TRSKIP_RATIO.