shithub: libvpx

Download patch

ref: fbefe470bf3661f6b3035312388dcf4215fdd836
parent: 29ade0d3cf4f8ad40e686cadbd2e46c245db817e
parent: 9f90473ef898d0ce41e053f1c529040795224ea1
author: Marco Paniconi <[email protected]>
date: Tue Apr 26 14:15:27 EDT 2016

Merge "vp9: Fix condition to update consec_zero_mv."

--- a/vp9/encoder/vp9_encodeframe.c
+++ b/vp9/encoder/vp9_encodeframe.c
@@ -4325,8 +4325,7 @@
   for (y = 0; y < ymis; y++)
     for (x = 0; x < xmis; x++) {
       int map_offset = block_index + y * cm->mi_cols + x;
-      if (is_inter_block(mi) && mi->skip &&
-          mi->segment_id <= CR_SEGMENT_ID_BOOST2) {
+      if (is_inter_block(mi) && mi->segment_id <= CR_SEGMENT_ID_BOOST2) {
         if (abs(mv.row) < 8 && abs(mv.col) < 8) {
           if (cpi->consec_zero_mv[map_offset] < 255)
            cpi->consec_zero_mv[map_offset]++;
--- a/vp9/encoder/vp9_noise_estimate.c
+++ b/vp9/encoder/vp9_noise_estimate.c
@@ -102,7 +102,7 @@
   NOISE_ESTIMATE *const ne = &cpi->noise_estimate;
   // Estimate of noise level every frame_period frames.
   int frame_period = 10;
-  int thresh_consec_zeromv = 8;
+  int thresh_consec_zeromv = 6;
   unsigned int thresh_sum_diff = 100;
   unsigned int thresh_sum_spatial = (200 * 200) << 8;
   unsigned int thresh_spatial_var = (32 * 32) << 8;
--- a/vp9/encoder/vp9_skin_detection.c
+++ b/vp9/encoder/vp9_skin_detection.c
@@ -88,7 +88,7 @@
                            int stride, int strideuv, int bsize,
                            int consec_zeromv, int curr_motion_magn) {
   // No skin if block has been zero/small motion for long consecutive time.
-  if (consec_zeromv > 80 && curr_motion_magn == 0) {
+  if (consec_zeromv > 60 && curr_motion_magn == 0) {
     return 0;
   } else {
     int motion = 1;
@@ -100,7 +100,7 @@
     const uint8_t ysource = y[y_height_shift * stride + y_width_shift];
     const uint8_t usource = u[uv_height_shift * strideuv + uv_width_shift];
     const uint8_t vsource = v[uv_height_shift * strideuv + uv_width_shift];
-    if (consec_zeromv > 30 && curr_motion_magn == 0)
+    if (consec_zeromv > 25 && curr_motion_magn == 0)
       motion = 0;
     return vp9_skin_pixel(ysource, usource, vsource, motion);
   }