Commit 3ca58dfb authored by Zoe Liu's avatar Zoe Liu
Browse files

A small cleanup on LOWDELAY_COMPOUND

BUG=aomedia:442

Change-Id: I98ada843016d0dd046f89bbcb2e9ae72442a101e
parent 05685e9a
...@@ -5413,29 +5413,15 @@ void av1_encode_frame(AV1_COMP *cpi) { ...@@ -5413,29 +5413,15 @@ void av1_encode_frame(AV1_COMP *cpi) {
// side behavior is where the ALT ref buffer has opposite sign bias to // side behavior is where the ALT ref buffer has opposite sign bias to
// the other two. // the other two.
if (!frame_is_intra_only(cm)) { if (!frame_is_intra_only(cm)) {
#if CONFIG_LOWDELAY_COMPOUND // Normative in encoder #if !CONFIG_LOWDELAY_COMPOUND
cpi->allow_comp_inter_inter = 1;
#if CONFIG_EXT_REFS
cm->comp_fwd_ref[0] = LAST_FRAME;
cm->comp_fwd_ref[1] = LAST2_FRAME;
cm->comp_fwd_ref[2] = LAST3_FRAME;
cm->comp_fwd_ref[3] = GOLDEN_FRAME;
cm->comp_bwd_ref[0] = BWDREF_FRAME;
cm->comp_bwd_ref[1] = ALTREF_FRAME;
#else
cm->comp_fixed_ref = ALTREF_FRAME;
cm->comp_var_ref[0] = LAST_FRAME;
cm->comp_var_ref[1] = GOLDEN_FRAME;
#endif // CONFIG_EXT_REFS
#else
if ((cm->ref_frame_sign_bias[ALTREF_FRAME] == if ((cm->ref_frame_sign_bias[ALTREF_FRAME] ==
cm->ref_frame_sign_bias[GOLDEN_FRAME]) || cm->ref_frame_sign_bias[GOLDEN_FRAME]) ||
(cm->ref_frame_sign_bias[ALTREF_FRAME] == (cm->ref_frame_sign_bias[ALTREF_FRAME] ==
cm->ref_frame_sign_bias[LAST_FRAME])) { cm->ref_frame_sign_bias[LAST_FRAME])) {
cpi->allow_comp_inter_inter = 0; cpi->allow_comp_inter_inter = 0;
} else { } else {
#endif
cpi->allow_comp_inter_inter = 1; cpi->allow_comp_inter_inter = 1;
#if CONFIG_EXT_REFS #if CONFIG_EXT_REFS
cm->comp_fwd_ref[0] = LAST_FRAME; cm->comp_fwd_ref[0] = LAST_FRAME;
cm->comp_fwd_ref[1] = LAST2_FRAME; cm->comp_fwd_ref[1] = LAST2_FRAME;
...@@ -5444,10 +5430,11 @@ void av1_encode_frame(AV1_COMP *cpi) { ...@@ -5444,10 +5430,11 @@ void av1_encode_frame(AV1_COMP *cpi) {
cm->comp_bwd_ref[0] = BWDREF_FRAME; cm->comp_bwd_ref[0] = BWDREF_FRAME;
cm->comp_bwd_ref[1] = ALTREF_FRAME; cm->comp_bwd_ref[1] = ALTREF_FRAME;
#else #else
cm->comp_fixed_ref = ALTREF_FRAME; cm->comp_fixed_ref = ALTREF_FRAME;
cm->comp_var_ref[0] = LAST_FRAME; cm->comp_var_ref[0] = LAST_FRAME;
cm->comp_var_ref[1] = GOLDEN_FRAME; cm->comp_var_ref[1] = GOLDEN_FRAME;
#endif // CONFIG_EXT_REFS #endif // CONFIG_EXT_REFS
#if !CONFIG_LOWDELAY_COMPOUND // Normative in encoder
} }
#endif #endif
} else { } else {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment