shithub: libvpx

Download patch

ref: d578bdad028735fda27730fb6617866d52dcaf29
parent: 9e1910297262aa8d338f0abdd8ed97cea1098b7e
author: Marco <marpan@google.com>
date: Mon Apr 17 05:19:03 EDT 2017

vp9: Datarate test: modify frame flags for 3 TL.

Modify the frame flags to update the ARF on top layer,
for the tests:
VP9/DatarateTestVP9Large.BasicRateTargeting3TemporalLayers
VP9/DatarateTestVP9Large.BasicRateTargeting3TemporalLayersFrameDropping

This is needed to fix the encode/decoder mismatches caused by 863f860,
and removed in the revert e9b7f98.

Change-Id: I6b9fecfdd17315fc0179e29949338c77636026c0

--- a/test/datarate_test.cc
+++ b/test/datarate_test.cc
@@ -496,8 +496,8 @@
   //      2           6
   // 0          4            ....
   // LAST is always update on base/layer 0, GOLDEN is updated on layer 1.
-  // For this 3 layer example, the 2nd enhancement layer (layer 2) does not
-  // update any reference frames.
+  // For this 3 layer example, the 2nd enhancement layer (layer 2) updates
+  // the altref frame.
   int SetFrameFlags(int frame_num, int num_temp_layers) {
     int frame_flags = 0;
     if (num_temp_layers == 2) {
@@ -519,9 +519,8 @@
         // Layer 1: predict from L, G, ARF; update G.
         frame_flags = VP8_EFLAG_NO_UPD_ARF | VP8_EFLAG_NO_UPD_LAST;
       } else if ((frame_num - 1) % 2 == 0) {
-        // Layer 2: predict from L, G, ARF; update none.
-        frame_flags =
-            VP8_EFLAG_NO_UPD_GF | VP8_EFLAG_NO_UPD_ARF | VP8_EFLAG_NO_UPD_LAST;
+        // Layer 2: predict from L, G, ARF; update ARF.
+        frame_flags = VP8_EFLAG_NO_UPD_GF | VP8_EFLAG_NO_UPD_LAST;
       }
     }
     return frame_flags;