From 6f6cd3abb963adb7d6521432391a4a61239247c8 Mon Sep 17 00:00:00 2001 From: Scott LaVarnway Date: Thu, 21 Apr 2011 14:59:42 -0400 Subject: [PATCH] Removed unnecessary frame type checks ref_frame is set to INTRA_FRAME for keyframes. The B_PRED mode is only used in intra frames. Change-Id: I9bac8bec7c736300d47994f3cb570329edf11ec0 --- vp8/decoder/decodframe.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/vp8/decoder/decodframe.c b/vp8/decoder/decodframe.c index e9655fb31..95985082f 100644 --- a/vp8/decoder/decodframe.c +++ b/vp8/decoder/decodframe.c @@ -111,9 +111,8 @@ void mb_init_dequantizer(VP8D_COMP *pbi, MACROBLOCKD *xd) */ static void skip_recon_mb(VP8D_COMP *pbi, MACROBLOCKD *xd) { - if (xd->frame_type == KEY_FRAME || xd->mode_info_context->mbmi.ref_frame == INTRA_FRAME) + if (xd->mode_info_context->mbmi.ref_frame == INTRA_FRAME) { - vp8_build_intra_predictors_mbuv_s(xd); RECON_INVOKE(&pbi->common.rtcd.recon, build_intra_predictors_mby_s)(xd); @@ -207,7 +206,7 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd) mb_init_dequantizer(pbi, xd); /* do prediction */ - if (xd->frame_type == KEY_FRAME || xd->mode_info_context->mbmi.ref_frame == INTRA_FRAME) + if (xd->mode_info_context->mbmi.ref_frame == INTRA_FRAME) { vp8_build_intra_predictors_mbuv(xd); @@ -254,7 +253,7 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd) xd->predictor, xd->dst.y_buffer, xd->dst.y_stride, xd->eobs, xd->block[24].diff); } - else if ((xd->frame_type == KEY_FRAME || xd->mode_info_context->mbmi.ref_frame == INTRA_FRAME) && xd->mode_info_context->mbmi.mode == B_PRED) + else if (xd->mode_info_context->mbmi.mode == B_PRED) { for (i = 0; i < 16; i++) {