shithub: libvpx

Download patch

ref: 14cc2c4709c37b4fde40b1d978f6081e5d7f4f09
parent: 8e9a41b30c464b75532ddc6d76257627d582ac1e
parent: 0df9a18edfe5969a3981ac65b7034480f36e8fe9
author: Jingning Han <jingning@google.com>
date: Wed May 8 17:29:07 EDT 2019

Merge "Fix key frame detection"

--- a/vp9/encoder/vp9_firstpass.c
+++ b/vp9/encoder/vp9_firstpass.c
@@ -2829,7 +2829,7 @@
   // See above for an explanation of the test criteria.
   // If so, then examine how well it predicts subsequent frames.
   if (!detect_flash(twopass, -1) && !detect_flash(twopass, 0) &&
-      (next_frame->pcnt_second_ref < SECOND_REF_USEAGE_THRESH) &&
+      (this_frame->pcnt_second_ref < SECOND_REF_USEAGE_THRESH) &&
       ((this_frame->pcnt_inter < VERY_LOW_INTER_THRESH) ||
        (slide_transition(this_frame, last_frame, next_frame)) ||
        (intra_step_transition(this_frame, last_frame, next_frame)) ||