summaryrefslogtreecommitdiff
path: root/vp9/encoder/vp9_encodeframe.c
diff options
context:
space:
mode:
Diffstat (limited to 'vp9/encoder/vp9_encodeframe.c')
-rw-r--r--vp9/encoder/vp9_encodeframe.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c
index 948d01bc3..7cc6e20a3 100644
--- a/vp9/encoder/vp9_encodeframe.c
+++ b/vp9/encoder/vp9_encodeframe.c
@@ -1090,6 +1090,7 @@ static int choose_partitioning(VP9_COMP *cpi, const TileInfo *const tile,
// If source_sad is low copy the partition without computing the y_sad.
if (x->skip_low_source_sad && cpi->sf.copy_partition_flag &&
copy_partitioning(cpi, x, xd, mi_row, mi_col, segment_id, sb_offset)) {
+ x->sb_use_mv_part = 1;
return 0;
}
}
@@ -1166,12 +1167,17 @@ static int choose_partitioning(VP9_COMP *cpi, const TileInfo *const tile,
mi->mv[0].as_int = 0;
mi->interp_filter = BILINEAR;
- if (cpi->oxcf.speed >= 8 && !low_res && x->content_state_sb != kVeryHighSad)
+ if (cpi->oxcf.speed >= 8 && !low_res &&
+ x->content_state_sb != kVeryHighSad) {
y_sad = cpi->fn_ptr[bsize].sdf(
x->plane[0].src.buf, x->plane[0].src.stride, xd->plane[0].pre[0].buf,
xd->plane[0].pre[0].stride);
- else
+ } else {
y_sad = vp9_int_pro_motion_estimation(cpi, x, bsize, mi_row, mi_col);
+ x->sb_use_mv_part = 1;
+ x->sb_mvcol_part = mi->mv[0].as_mv.col;
+ x->sb_mvrow_part = mi->mv[0].as_mv.row;
+ }
y_sad_last = y_sad;
// Pick ref frame for partitioning, bias last frame when y_sad_g and y_sad
@@ -4145,6 +4151,9 @@ static void encode_nonrd_sb_row(VP9_COMP *cpi, ThreadData *td,
x->skip_low_source_sad = 0;
x->lowvar_highsumdiff = 0;
x->content_state_sb = 0;
+ x->sb_use_mv_part = 0;
+ x->sb_mvcol_part = 0;
+ x->sb_mvrow_part = 0;
if (seg->enabled) {
const uint8_t *const map =