sf->thresh_mult_sub8x8[THR_COMP_GA] = INT_MAX;
}
-static void set_good_speed_feature(VP9_COMMON *cm,
+// Intra only frames, golden frames (except alt ref overlays) and
+// alt ref frames tend to be coded at a higher than ambient quality
+static INLINE int frame_is_boosted(const VP9_COMP *cpi,
+ const VP9_COMMON *const cm) {
+ return frame_is_intra_only(cm) || cpi->refresh_alt_ref_frame ||
+ (cpi->refresh_golden_frame && !cpi->rc.is_src_frame_alt_ref);
+}
+
+static void set_good_speed_feature(VP9_COMP *cpi,
+ VP9_COMMON *cm,
SPEED_FEATURES *sf,
int speed) {
int i;
if (speed == 1) {
sf->use_square_partition_only = !frame_is_intra_only(cm);
sf->less_rectangular_check = 1;
- sf->tx_size_search_method = frame_is_intra_only(cm)
+ sf->tx_size_search_method = frame_is_boosted(cpi, cm)
? USE_FULL_RD : USE_LARGESTALL;
if (MIN(cm->width, cm->height) >= 720)
sf->intra_y_mode_mask[TX_32X32] = INTRA_DC_H_V;
sf->intra_uv_mode_mask[TX_32X32] = INTRA_DC_H_V;
sf->intra_uv_mode_mask[TX_16X16] = INTRA_DC_H_V;
+ sf->subpel_iters_per_step = 1;
+ sf->mode_skip_start = 10;
}
if (speed == 2) {
sf->use_square_partition_only = !frame_is_intra_only(cm);
case MODE_FIRSTPASS:
case MODE_GOODQUALITY:
case MODE_SECONDPASS:
- set_good_speed_feature(cm, sf, speed);
+ set_good_speed_feature(cpi, cm, sf, speed);
break;
case MODE_REALTIME:
set_rt_speed_feature(cm, sf, speed);