summaryrefslogtreecommitdiff
path: root/vp8/encoder/bitstream.c
diff options
context:
space:
mode:
authorRonald S. Bultje <rbultje@google.com>2012-02-09 16:11:00 -0800
committerRonald S. Bultje <rbultje@google.com>2012-02-09 16:29:18 -0800
commit29e4d7e861eb044902a34291df0814e972e28bcb (patch)
tree37b53377a9f1006294bf0a9d2e31ebcfcfdf6393 /vp8/encoder/bitstream.c
parentd90f0eb4c559595262f2cebc39adbfbbdf855efb (diff)
downloadlibvpx-29e4d7e861eb044902a34291df0814e972e28bcb.tar
libvpx-29e4d7e861eb044902a34291df0814e972e28bcb.tar.gz
libvpx-29e4d7e861eb044902a34291df0814e972e28bcb.tar.bz2
libvpx-29e4d7e861eb044902a34291df0814e972e28bcb.zip
Merge dualpred (compound prediction) experiment.
Change-Id: Ieaaa07c50eae41118596197f6a4d848135946e41
Diffstat (limited to 'vp8/encoder/bitstream.c')
-rw-r--r--vp8/encoder/bitstream.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/vp8/encoder/bitstream.c b/vp8/encoder/bitstream.c
index b318cc557..4f7b9df69 100644
--- a/vp8/encoder/bitstream.c
+++ b/vp8/encoder/bitstream.c
@@ -967,9 +967,7 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
const MV_CONTEXT *mvc = pc->fc.mvc;
MACROBLOCKD *xd = &cpi->mb.e_mbd;
-#if CONFIG_DUALPRED
int i;
-#endif
int pred_context;
MODE_INFO *m = pc->mi;
@@ -1022,7 +1020,6 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
vp8_write_literal(w, pc->prob_last_coded, 8);
vp8_write_literal(w, pc->prob_gf_coded, 8);
-#if CONFIG_DUALPRED
if (cpi->common.dual_pred_mode == HYBRID_PREDICTION)
{
vp8_write(w, 1, 128);
@@ -1052,7 +1049,6 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
vp8_write(w, 1, 128);
vp8_write(w, 0, 128);
}
-#endif /* CONFIG_DUALPRED */
update_mbintra_mode_probs(cpi);
@@ -1220,7 +1216,7 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
#endif
write_mv(w, &mi->mv.as_mv, &best_mv, mvc);
-#if CONFIG_DUALPRED
+
if (cpi->common.dual_pred_mode == HYBRID_PREDICTION)
{
vp8_write(w,
@@ -1239,7 +1235,6 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
cpi->common.ref_frame_sign_bias);
write_mv(w, &mi->second_mv.as_mv, &best_mv, mvc);
}
-#endif /* CONFIG_DUALPRED */
break;
case SPLITMV:
@@ -1288,14 +1283,12 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
}
break;
default:
-#if CONFIG_DUALPRED
if (cpi->common.dual_pred_mode == HYBRID_PREDICTION)
{
vp8_write(w,
mi->second_ref_frame != INTRA_FRAME,
get_pred_prob( pc, xd, PRED_DUAL ) );
}
-#endif /* CONFIG_DUALPRED */
break;
}
}
@@ -1326,9 +1319,7 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
const MV_CONTEXT *mvc = pc->fc.mvc;
MACROBLOCKD *xd = &cpi->mb.e_mbd;
-#if CONFIG_DUALPRED
int i;
-#endif
int pred_context;
@@ -1378,7 +1369,6 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
vp8_write_literal(w, pc->prob_last_coded, 8);
vp8_write_literal(w, pc->prob_gf_coded, 8);
-#if CONFIG_DUALPRED
if (cpi->common.dual_pred_mode == HYBRID_PREDICTION)
{
vp8_write(w, 1, 128);
@@ -1408,7 +1398,6 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
vp8_write(w, 1, 128);
vp8_write(w, 0, 128);
}
-#endif /* CONFIG_DUALPRED */
update_mbintra_mode_probs(cpi);
@@ -1556,7 +1545,7 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
#endif
write_mv(w, &mi->mv.as_mv, &best_mv, mvc);
-#if CONFIG_DUALPRED
+
if (cpi->common.dual_pred_mode == HYBRID_PREDICTION)
{
vp8_write(w, mi->second_ref_frame != INTRA_FRAME,
@@ -1574,7 +1563,6 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
cpi->common.ref_frame_sign_bias);
write_mv(w, &mi->second_mv.as_mv, &best_mv, mvc);
}
-#endif /* CONFIG_DUALPRED */
break;
case SPLITMV:
{
@@ -1622,13 +1610,11 @@ static void pack_inter_mode_mvs(VP8_COMP *const cpi)
}
break;
default:
-#if CONFIG_DUALPRED
if (cpi->common.dual_pred_mode == HYBRID_PREDICTION)
{
vp8_write(w, mi->second_ref_frame != INTRA_FRAME,
get_pred_prob( pc, xd, PRED_DUAL ) );
}
-#endif /* CONFIG_DUALPRED */
break;
}
}