summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vp9/encoder/vp9_aq_cyclicrefresh.c4
-rw-r--r--vp9/encoder/vp9_encodeframe.c2
-rw-r--r--vp9/encoder/vp9_encoder.c11
-rw-r--r--vp9/encoder/vp9_pickmode.c28
-rw-r--r--vp9/encoder/vp9_segmentation.c2
-rw-r--r--vp9/encoder/vp9_speed_features.c3
6 files changed, 16 insertions, 34 deletions
diff --git a/vp9/encoder/vp9_aq_cyclicrefresh.c b/vp9/encoder/vp9_aq_cyclicrefresh.c
index 5cc0e0372..b3b546044 100644
--- a/vp9/encoder/vp9_aq_cyclicrefresh.c
+++ b/vp9/encoder/vp9_aq_cyclicrefresh.c
@@ -530,9 +530,9 @@ void vp9_cyclic_refresh_update_parameters(VP9_COMP *const cpi) {
cr->rate_boost_fac = 10;
}
// Adjust some parameters for low resolutions.
- if (cm->width <= 352 && cm->height <= 288) {
+ if (cm->width * cm->height <= 352 * 288) {
if (rc->avg_frame_bandwidth < 3000) {
- cr->motion_thresh = 16;
+ cr->motion_thresh = 64;
cr->rate_boost_fac = 13;
} else {
cr->max_qdelta_perc = 70;
diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c
index 999ec6139..c2669b03f 100644
--- a/vp9/encoder/vp9_encodeframe.c
+++ b/vp9/encoder/vp9_encodeframe.c
@@ -5901,7 +5901,7 @@ static void encode_frame_internal(VP9_COMP *cpi) {
if (cm->show_frame) {
int mi_row, mi_col;
cpi->kmeans_data_size = 0;
- cpi->kmeans_ctr_num = 5;
+ cpi->kmeans_ctr_num = 8;
for (mi_row = 0; mi_row < cm->mi_rows; mi_row += MI_BLOCK_SIZE)
for (mi_col = 0; mi_col < cm->mi_cols; mi_col += MI_BLOCK_SIZE)
diff --git a/vp9/encoder/vp9_encoder.c b/vp9/encoder/vp9_encoder.c
index 2a9a36f61..03e8ed674 100644
--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -4746,13 +4746,16 @@ static void set_mb_wiener_variance(VP9_COMP *cpi) {
#if CONFIG_VP9_HIGHBITDEPTH
xd->cur_buf = cpi->Source;
- if (xd->cur_buf->flags & YV12_FLAG_HIGHBITDEPTH)
+ if (xd->cur_buf->flags & YV12_FLAG_HIGHBITDEPTH) {
zero_pred = CONVERT_TO_BYTEPTR(zero_pred16);
- else
+ memset(zero_pred16, 0, sizeof(*zero_pred16) * coeff_count);
+ } else {
zero_pred = zero_pred8;
-#endif
-
+ memset(zero_pred8, 0, sizeof(*zero_pred8) * coeff_count);
+ }
+#else
memset(zero_pred, 0, sizeof(*zero_pred) * coeff_count);
+#endif
cpi->norm_wiener_variance = 0;
diff --git a/vp9/encoder/vp9_pickmode.c b/vp9/encoder/vp9_pickmode.c
index 86831b972..54479b59b 100644
--- a/vp9/encoder/vp9_pickmode.c
+++ b/vp9/encoder/vp9_pickmode.c
@@ -680,25 +680,6 @@ static void block_yrd(VP9_COMP *cpi, MACROBLOCK *x, RD_COST *this_rdc,
const int bw = 4 * num_4x4_w;
const int bh = 4 * num_4x4_h;
-#if CONFIG_VP9_HIGHBITDEPTH
- // TODO(jingning): Implement the high bit-depth Hadamard transforms and
- // remove this check condition.
- // TODO(marpan): Use this path (model_rd) for 8bit under certain conditions
- // for now, as the vp9_quantize_fp below for highbitdepth build is slow.
- if (xd->bd != 8 ||
- (cpi->oxcf.speed > 5 && cpi->common.frame_type != KEY_FRAME &&
- bsize < BLOCK_32X32)) {
- unsigned int var_y, sse_y;
- (void)tx_size;
- if (!rd_computed)
- model_rd_for_sb_y(cpi, bsize, x, xd, &this_rdc->rate, &this_rdc->dist,
- &var_y, &sse_y);
- *sse = INT_MAX;
- *skippable = 0;
- return;
- }
-#endif
-
if (cpi->sf.use_simple_block_yrd && cpi->common.frame_type != KEY_FRAME &&
(bsize < BLOCK_32X32 ||
(cpi->use_svc &&
@@ -1700,11 +1681,10 @@ void vp9_pick_inter_mode(VP9_COMP *cpi, MACROBLOCK *x, TileDataEnc *tile_data,
int no_scaling = 0;
unsigned int thresh_svc_skip_golden = 500;
unsigned int thresh_skip_golden = 500;
- int force_smooth_filter =
- (cpi->oxcf.speed >= 8 && cm->width * cm->height <= 320 * 240 &&
- cm->base_qindex >= 200)
- ? 1
- : 0;
+ // TODO(marpan/jianj): forcing smooth_interpol is visually better for noisy
+ // content, at low resolns. Look into adding this conditon. For now keep
+ // it off.
+ int force_smooth_filter = 0;
int scene_change_detected =
cpi->rc.high_source_sad ||
(cpi->use_svc && cpi->svc.high_source_sad_superframe);
diff --git a/vp9/encoder/vp9_segmentation.c b/vp9/encoder/vp9_segmentation.c
index 846ee3bb9..a163297e6 100644
--- a/vp9/encoder/vp9_segmentation.c
+++ b/vp9/encoder/vp9_segmentation.c
@@ -67,7 +67,7 @@ void vp9_perceptual_aq_mode_setup(struct VP9_COMP *cpi,
const int base_qindex = cm->base_qindex;
const double base_qstep = vp9_convert_qindex_to_q(base_qindex, cm->bit_depth);
const double mid_ctr = cpi->kmeans_ctr_ls[seg_counts / 2];
- const double var_diff_scale = 8.0;
+ const double var_diff_scale = 4.0;
int i;
assert(seg_counts <= MAX_SEGMENTS);
diff --git a/vp9/encoder/vp9_speed_features.c b/vp9/encoder/vp9_speed_features.c
index 92c115fd1..836642594 100644
--- a/vp9/encoder/vp9_speed_features.c
+++ b/vp9/encoder/vp9_speed_features.c
@@ -720,8 +720,7 @@ static void set_rt_speed_feature_framesize_independent(
if (!frame_is_intra_only(cm) && cm->width * cm->height <= 352 * 288) {
sf->nonrd_use_ml_partition = 1;
}
- if (content == VP9E_CONTENT_SCREEN) sf->mv.subpel_force_stop = FULL_PEL;
- if (content == VP9E_CONTENT_SCREEN) sf->lpf_pick = LPF_PICK_MINIMAL_LPF;
+ if (content == VP9E_CONTENT_SCREEN) sf->mv.subpel_force_stop = HALF_PEL;
// Only keep INTRA_DC mode for speed 8.
if (!is_keyframe) {
int i = 0;