From c9ff7b66372581af8960a5dab5ca498999bd538a Mon Sep 17 00:00:00 2001 From: Marco Date: Wed, 23 Aug 2017 13:01:57 -0700 Subject: [PATCH] vp9: SVC: Skip NEWMV for small blocks for (0, 0) base_mv. For SVC encoding: average speedup ~1.5%, with small ~0.57 loss in avgPSNR metrics. Change-Id: Icebce6f6ef4e819d7dfcf8db898c583167351de4 --- vp9/encoder/vp9_pickmode.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/vp9/encoder/vp9_pickmode.c b/vp9/encoder/vp9_pickmode.c index fdd31c7dc..3340a09fb 100644 --- a/vp9/encoder/vp9_pickmode.c +++ b/vp9/encoder/vp9_pickmode.c @@ -1805,6 +1805,14 @@ void vp9_pick_inter_mode(VP9_COMP *cpi, MACROBLOCK *x, TileDataEnc *tile_data, (frame_mv[NEWMV][ref_frame].as_mv.col >> 3); cpi->fn_ptr[bsize].vf(x->plane[0].src.buf, x->plane[0].src.stride, pre_buf, pre_stride, &base_mv_sse); + + // Exit NEWMV search if base_mv is (0,0) && bsize < BLOCK_16x16, + // for SVC encoding. + if (cpi->use_svc && cpi->svc.use_base_mv && bsize < BLOCK_16X16 && + frame_mv[NEWMV][ref_frame].as_mv.row == 0 && + frame_mv[NEWMV][ref_frame].as_mv.col == 0) + continue; + // Exit NEWMV search if base_mv_sse is large. if (sf->base_mv_aggressive && base_mv_sse > (best_sse_sofar << scale)) continue; -- 2.40.0