]> granicus.if.org Git - libvpx/commitdiff
Adjust threshold in scene detection
authorMarco <marpan@google.com>
Fri, 6 Oct 2017 17:53:40 +0000 (10:53 -0700)
committerMarco <marpan@google.com>
Fri, 6 Oct 2017 18:08:56 +0000 (11:08 -0700)
For 1 pass vbr: increase min_thresh slightly, and also add
condition on golden/arf update for using full nonrd_pick_partition.

Reduces possible false detection for scene cut detection.

Neutral/small change in metrics or speed for speed 5.

Change-Id: I388f4d9a56e3cc763e0148338c1bc0381e58ad76

vp9/encoder/vp9_encodeframe.c
vp9/encoder/vp9_ratectrl.c

index c9d865e5caa60bb7c31c508e0702fccf69097b2f..dee17ade2f4738c14a203f7d34fa65604f62e6a9 100644 (file)
@@ -4216,7 +4216,8 @@ static void encode_nonrd_sb_row(VP9_COMP *cpi, ThreadData *td,
         // nonrd_pick_partition does not support 4x4 partition, so avoid it
         // on key frame for now.
         if ((cpi->oxcf.rc_mode == VPX_VBR && cpi->rc.high_source_sad &&
-             cpi->oxcf.speed < 6 && cm->frame_type != KEY_FRAME)) {
+             cpi->oxcf.speed < 6 && cm->frame_type != KEY_FRAME &&
+             (cpi->refresh_golden_frame || cpi->refresh_alt_ref_frame))) {
           // Use lower max_partition_size for low resoultions.
           if (cm->width <= 352 && cm->height <= 288)
             x->max_partition_size = BLOCK_32X32;
index e796b66e0ffa0cd9cae43fcbd48cf692866cb9f4..536af35fa905a2d775a23e1c7331d1e6a9bc901c 100644 (file)
@@ -2280,7 +2280,7 @@ void vp9_scene_detection_onepass(VP9_COMP *cpi) {
     uint32_t min_thresh = 4000;
     float thresh = 8.0f;
     if (cpi->oxcf.rc_mode == VPX_VBR) {
-      min_thresh = 60000;
+      min_thresh = 70000;
       thresh = 2.1f;
     }
     if (cpi->oxcf.lag_in_frames > 0) {