From ed7786869aaa5b191450c674ddbf410aa5803c5b Mon Sep 17 00:00:00 2001 From: Scott LaVarnway Date: Sat, 9 Jul 2016 09:47:34 -0700 Subject: [PATCH] vp9_rd_pick_intra_mode_sb(): set interp_filter to SWITCHABLE_FILTERS. This is a partial fix for the build issues with Change 357240. Change-Id: I4e507c196175bae729a4f1397878ec8776b0146c --- vp9/encoder/vp9_encodeframe.c | 6 ++++++ vp9/encoder/vp9_rdopt.c | 3 +++ 2 files changed, 9 insertions(+) diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c index f55804c97..640a54637 100644 --- a/vp9/encoder/vp9_encodeframe.c +++ b/vp9/encoder/vp9_encodeframe.c @@ -2751,6 +2751,12 @@ static void rd_pick_partition(VP9_COMP *cpi, ThreadData *td, if (cpi->sf.adaptive_motion_search) store_pred_mv(x, ctx); + // If the interp_filter is marked as SWITCHABLE_FILTERS, it was for an + // intra block and used for context purposes. + if (ctx->mic.interp_filter == SWITCHABLE_FILTERS) { + ctx->mic.interp_filter = EIGHTTAP; + } + // PARTITION_SPLIT // TODO(jingning): use the motion vectors given by the above search as // the starting point of motion search in the following partition type check. diff --git a/vp9/encoder/vp9_rdopt.c b/vp9/encoder/vp9_rdopt.c index 0ed085055..d5a14eff8 100644 --- a/vp9/encoder/vp9_rdopt.c +++ b/vp9/encoder/vp9_rdopt.c @@ -2794,6 +2794,9 @@ void vp9_rd_pick_intra_mode_sb(VP9_COMP *cpi, MACROBLOCK *x, ctx->skip = 0; xd->mi[0]->ref_frame[0] = INTRA_FRAME; xd->mi[0]->ref_frame[1] = NONE; + // Initialize interp_filter here so we do not have to check for inter block + // modes in get_pred_context_switchable_interp() + xd->mi[0]->interp_filter = SWITCHABLE_FILTERS; if (bsize >= BLOCK_8X8) { if (rd_pick_intra_sby_mode(cpi, x, &rate_y, &rate_y_tokenonly,