From c90b6bb101927d6a02a98fbf4360911ad48247c4 Mon Sep 17 00:00:00 2001 From: Dmitry Kovalev Date: Wed, 20 Nov 2013 17:14:40 -0800 Subject: [PATCH] Removing redundant call of vp9_init_mbmode_probs(). This function is called from vp9_setup_past_independence() which is called before the modified piece of code. Moving reset of inter_mode_probs into vp9_init_mbmode_probs() for consistency. Change-Id: Ib188e8798e1fbe15407fd501406761b746fdda95 --- vp9/common/vp9_entropymode.c | 2 +- vp9/encoder/vp9_encodeframe.c | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/vp9/common/vp9_entropymode.c b/vp9/common/vp9_entropymode.c index 3b2510dcd..5d74c6967 100644 --- a/vp9/common/vp9_entropymode.c +++ b/vp9/common/vp9_entropymode.c @@ -329,6 +329,7 @@ void vp9_init_mbmode_probs(VP9_COMMON *cm) { vp9_copy(cm->fc.single_ref_prob, default_single_ref_p); cm->fc.tx_probs = default_tx_probs; vp9_copy(cm->fc.mbskip_probs, default_mbskip_probs); + vp9_copy(cm->fc.inter_mode_probs, default_inter_mode_probs); } const vp9_tree_index vp9_switchable_interp_tree @@ -466,7 +467,6 @@ void vp9_setup_past_independence(VP9_COMMON *cm) { vp9_default_coef_probs(cm); vp9_init_mbmode_probs(cm); vp9_init_mv_probs(cm); - vp9_copy(cm->fc.inter_mode_probs, default_inter_mode_probs); if (cm->frame_type == KEY_FRAME || cm->error_resilient_mode || cm->reset_frame_context == 3) { diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c index 2a85deec8..7cda45612 100644 --- a/vp9/encoder/vp9_encodeframe.c +++ b/vp9/encoder/vp9_encodeframe.c @@ -1868,10 +1868,6 @@ static void init_encode_frame_mb_context(VP9_COMP *cpi) { xd->mode_info_stride = cm->mode_info_stride; - // reset intra mode contexts - if (frame_is_intra_only(cm)) - vp9_init_mbmode_probs(cm); - // Copy data over into macro block data structures. vp9_setup_src_planes(x, cpi->Source, 0, 0); -- 2.40.0