]> granicus.if.org Git - libvpx/commitdiff
Adjusting thresholds in mfqe post-processing
authorDeb Mukherjee <debargha@google.com>
Tue, 4 Sep 2012 19:09:05 +0000 (12:09 -0700)
committerDeb Mukherjee <debargha@google.com>
Tue, 4 Sep 2012 19:30:09 +0000 (12:30 -0700)
Adjusts some of the qualification thresholds in mfqe to eliminate
artifacts due to wrong decisions. Besides, a new qualification
criteria is used to disable mfqe if the quality of the previous
frame is itself not too good.

Change-Id: I4097c20b7fd4fcc60cc3003c1e33e8faae2ff066

vp8/common/mfqe.c
vp8/common/postproc.c

index 3fe5bca3d8bcd92f8815feb18e69527ab7e66caf..3dff1505b04e05367f7a101d462534d4675bf877 100644 (file)
@@ -185,8 +185,8 @@ static void multiframe_quality_enhance_block
 
     actrisk = (actd > act * 5);
 
-    /* thr = qdiff/8 + log2(act) + log4(qprev) */
-    thr = (qdiff >> 3);
+    /* thr = qdiff/16 + log2(act) + log4(qprev) */
+    thr = (qdiff >> 4);
     while (actd >>= 1) thr++;
     while (qprev >>= 2) thr++;
 
index a7509ff4e28d5460afc7cda4ec4be265e83fec2c..44489878470bf55a7df3850ae20788c56860bf03 100644 (file)
@@ -742,7 +742,8 @@ int vp8_post_proc_frame(VP8_COMMON *oci, YV12_BUFFER_CONFIG *dest, vp8_ppflags_t
     if ((flags & VP8D_MFQE) &&
          oci->postproc_state.last_frame_valid &&
          oci->current_video_frame >= 2 &&
-         oci->base_qindex - oci->postproc_state.last_base_qindex >= 10)
+         oci->postproc_state.last_base_qindex < 60 &&
+         oci->base_qindex - oci->postproc_state.last_base_qindex >= 20)
     {
         vp8_multiframe_quality_enhance(oci);
         if (((flags & VP8D_DEBLOCK) || (flags & VP8D_DEMACROBLOCK)) &&