summaryrefslogtreecommitdiff
path: root/vp9
diff options
context:
space:
mode:
authorJackyChen <jackychen@google.com>2014-09-10 13:19:42 -0700
committerJackyChen <jackychen@google.com>2014-09-10 16:18:43 -0700
commit47380c335071517b57ebb5c67248831402562ead (patch)
treed90e3eb6dd0727837e4976a736f55683d5ce1b95 /vp9
parent0e66848081c19e75bf68ace1ac8f93220c4af68e (diff)
downloadlibvpx-47380c335071517b57ebb5c67248831402562ead.tar
libvpx-47380c335071517b57ebb5c67248831402562ead.tar.gz
libvpx-47380c335071517b57ebb5c67248831402562ead.tar.bz2
libvpx-47380c335071517b57ebb5c67248831402562ead.zip
Fix the bug which made VP8 denoiser not bit-exact between C code and SSE code.
This issue is found when the denoising mode is set to kDenoiserOnYUVAggressive. Updated the C code to make it the same with SSE version. I also changed several lines in VP9 denoiser for the code style. Change-Id: I640d48cf946fe8c6a400e6e252107501d1e226d3
Diffstat (limited to 'vp9')
-rw-r--r--vp9/encoder/vp9_denoiser.c6
-rw-r--r--vp9/encoder/vp9_denoiser.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/vp9/encoder/vp9_denoiser.c b/vp9/encoder/vp9_denoiser.c
index c4cf5eeb6..75b94499d 100644
--- a/vp9/encoder/vp9_denoiser.c
+++ b/vp9/encoder/vp9_denoiser.c
@@ -89,9 +89,9 @@ static VP9_DENOISER_DECISION denoiser_filter(const uint8_t *sig, int sig_stride,
int total_adj = 0;
int shift_inc = 1;
- /* If motion_magnitude is small, making the denoiser more aggressive by
- * increasing the adjustment for each level. Add another increment for
- * blocks that are labeled for increase denoising. */
+ // If motion_magnitude is small, making the denoiser more aggressive by
+ // increasing the adjustment for each level. Add another increment for
+ // blocks that are labeled for increase denoising.
if (motion_magnitude <= MOTION_MAGNITUDE_THRESHOLD) {
if (increase_denoising) {
shift_inc = 2;
diff --git a/vp9/encoder/vp9_denoiser.h b/vp9/encoder/vp9_denoiser.h
index a913add86..fa714b132 100644
--- a/vp9/encoder/vp9_denoiser.h
+++ b/vp9/encoder/vp9_denoiser.h
@@ -18,7 +18,7 @@
extern "C" {
#endif
-#define MOTION_MAGNITUDE_THRESHOLD (8*3)
+#define MOTION_MAGNITUDE_THRESHOLD (8 * 3)
typedef enum vp9_denoiser_decision {
COPY_BLOCK,