Index: source/libvpx/vp9/encoder/vp9_speed_features.c |
diff --git a/source/libvpx/vp9/encoder/vp9_speed_features.c b/source/libvpx/vp9/encoder/vp9_speed_features.c |
index cc6df1fd6a9633bb38a9c98651db1e56d5b1b989..8530f9809a71544f9a5f89304d44633b5e9ee3ed 100644 |
--- a/source/libvpx/vp9/encoder/vp9_speed_features.c |
+++ b/source/libvpx/vp9/encoder/vp9_speed_features.c |
@@ -49,7 +49,7 @@ static void set_good_speed_feature_framesize_dependent(VP9_COMP *cpi, |
VP9_COMMON *const cm = &cpi->common; |
if (speed >= 1) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->disable_split_mask = cm->show_frame ? DISABLE_ALL_SPLIT |
: DISABLE_ALL_INTER_SPLIT; |
sf->partition_search_breakout_dist_thr = (1 << 23); |
@@ -60,7 +60,7 @@ static void set_good_speed_feature_framesize_dependent(VP9_COMP *cpi, |
} |
if (speed >= 2) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->disable_split_mask = cm->show_frame ? DISABLE_ALL_SPLIT |
: DISABLE_ALL_INTER_SPLIT; |
sf->adaptive_pred_interp_filter = 0; |
@@ -75,7 +75,7 @@ static void set_good_speed_feature_framesize_dependent(VP9_COMP *cpi, |
} |
if (speed >= 3) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->disable_split_mask = DISABLE_ALL_SPLIT; |
sf->schedule_mode_search = cm->base_qindex < 220 ? 1 : 0; |
sf->partition_search_breakout_dist_thr = (1 << 25); |
@@ -99,7 +99,7 @@ static void set_good_speed_feature_framesize_dependent(VP9_COMP *cpi, |
} |
if (speed >= 4) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->partition_search_breakout_dist_thr = (1 << 26); |
} else { |
sf->partition_search_breakout_dist_thr = (1 << 24); |
@@ -215,7 +215,7 @@ static void set_rt_speed_feature_framesize_dependent(VP9_COMP *cpi, |
VP9_COMMON *const cm = &cpi->common; |
if (speed >= 1) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->disable_split_mask = cm->show_frame ? DISABLE_ALL_SPLIT |
: DISABLE_ALL_INTER_SPLIT; |
} else { |
@@ -224,7 +224,7 @@ static void set_rt_speed_feature_framesize_dependent(VP9_COMP *cpi, |
} |
if (speed >= 2) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->disable_split_mask = cm->show_frame ? DISABLE_ALL_SPLIT |
: DISABLE_ALL_INTER_SPLIT; |
} else { |
@@ -233,7 +233,7 @@ static void set_rt_speed_feature_framesize_dependent(VP9_COMP *cpi, |
} |
if (speed >= 5) { |
- if (MIN(cm->width, cm->height) >= 720) { |
+ if (VPXMIN(cm->width, cm->height) >= 720) { |
sf->partition_search_breakout_dist_thr = (1 << 25); |
} else { |
sf->partition_search_breakout_dist_thr = (1 << 23); |
@@ -241,7 +241,7 @@ static void set_rt_speed_feature_framesize_dependent(VP9_COMP *cpi, |
} |
if (speed >= 7) { |
- sf->encode_breakout_thresh = (MIN(cm->width, cm->height) >= 720) ? |
+ sf->encode_breakout_thresh = (VPXMIN(cm->width, cm->height) >= 720) ? |
800 : 300; |
} |
} |
@@ -394,6 +394,11 @@ static void set_rt_speed_feature(VP9_COMP *cpi, SPEED_FEATURES *sf, |
sf->adaptive_rd_thresh = 3; |
sf->mv.search_method = FAST_DIAMOND; |
sf->mv.fullpel_search_step_param = 10; |
+ if (cpi->svc.number_temporal_layers > 2 && |
+ cpi->svc.temporal_layer_id == 0) { |
+ sf->mv.search_method = NSTEP; |
+ sf->mv.fullpel_search_step_param = 6; |
+ } |
} |
if (speed >= 8) { |
sf->adaptive_rd_thresh = 4; |