]> granicus.if.org Git - libvpx/commitdiff
vp9: Fix to noise estimation for temporal denoising.
authorMarco <marpan@google.com>
Thu, 6 Apr 2017 23:35:01 +0000 (16:35 -0700)
committerMarco <marpan@google.com>
Fri, 7 Apr 2017 16:23:30 +0000 (09:23 -0700)
If the noise estimation is avoided due to large motion,
the last_source for denoising should still be updated.

Change-Id: I67155ea7dbe9ac2785978e64a27bdafd7d57aac0

vp9/encoder/vp9_noise_estimate.c

index fd6a4eee5d27f78c047097ce72dec345641b2370..fc2e32448e884e2459bc4f2c961bd2b3a9a8d69a 100644 (file)
@@ -132,8 +132,10 @@ void vp9_update_noise_estimate(VP9_COMP *const cpi) {
     ne->level = kLowLow;
 #if CONFIG_VP9_TEMPORAL_DENOISING
     if (cpi->oxcf.noise_sensitivity > 0 && denoise_svc(cpi) &&
-        cpi->svc.current_superframe > 1)
+        cpi->svc.current_superframe > 1) {
       vp9_denoiser_set_noise_level(&cpi->denoiser, ne->level);
+      copy_frame(&cpi->denoiser.last_source, cpi->Source);
+    }
 #endif
     return;
   } else {