vp9: Add condition of real-time mode to scene detection.
authorMarco Paniconi <marpan@google.com>
Thu, 19 Apr 2018 00:46:16 +0000 (17:46 -0700)
committerMarco Paniconi <marpan@google.com>
Thu, 19 Apr 2018 00:48:54 +0000 (17:48 -0700)
This was removed by error from the change: ce11afb, and
made some datarate tests fail.

Change-Id: I0c29e1f5aede8f56ce835b25fed0528722350241

vp9/encoder/vp9_encoder.c

index 9ec5397..2f92456 100644 (file)
@@ -3683,7 +3683,7 @@ static void encode_without_recode_loop(VP9_COMP *cpi, size_t *size,
   // For other cases (e.g., CBR mode) use it for 5 <= speed < 8 for now
   // (need to check encoding time cost for doing this for speed 8).
   cpi->rc.high_source_sad = 0;
-  if (cm->show_frame &&
+  if (cm->show_frame && cpi->oxcf.mode == REALTIME &&
       (cpi->oxcf.rc_mode == VPX_VBR ||
        cpi->oxcf.content == VP9E_CONTENT_SCREEN ||
        (cpi->oxcf.speed >= 5 && cpi->oxcf.speed < 8 && !cpi->use_svc)))