]> granicus.if.org Git - libvpx/commitdiff
Silence some harmless compiler warnings in CLPF.
authorSteinar Midtskogen <stemidts@cisco.com>
Fri, 2 Sep 2016 08:02:30 +0000 (10:02 +0200)
committerYaowu Xu <yaowu@google.com>
Mon, 10 Oct 2016 18:20:43 +0000 (11:20 -0700)
Change-Id: I4a6d84007bc17b89cfd8d8f2440bf2968505bd6a

av1/common/clpf.c
av1/decoder/decodeframe.c
av1/encoder/clpf_rdo.c

index 388a7c93af2b4ea64b1664dc175c840bb04e9874..6739809c0bf411b39cd7cf76a4c0ac5debd8333d 100644 (file)
@@ -63,7 +63,6 @@ int av1_clpf_frame(const YV12_BUFFER_CONFIG *dst, const YV12_BUFFER_CONFIG *rec,
   int height = rec->y_crop_height;
   int xpos, ypos;
   int stride_y = rec->y_stride;
-  int stride_c = rec->uv_stride;
   const int bs = MAX_MIB_SIZE;
   int num_fb_hor = (width + (1 << fb_size_log2) - bs) >> fb_size_log2;
   int num_fb_ver = (height + (1 << fb_size_log2) - bs) >> fb_size_log2;
index 51ef4758d944ea8c54db726d2df46318926efd2b..dc18944b3a3b209bce9faf626fb55f55191efbe9 100644 (file)
@@ -17,6 +17,7 @@
 #include "./aom_scale_rtcd.h"
 #include "./av1_rtcd.h"
 
+#include "aom/aom_codec.h"
 #include "aom_dsp/aom_dsp_common.h"
 #include "aom_dsp/bitreader.h"
 #include "aom_dsp/bitreader_buffer.h"
@@ -2059,10 +2060,12 @@ static void setup_clpf(AV1_COMMON *cm, struct aom_read_bit_buffer *rb) {
   }
 }
 
-static int clpf_bit(int k, int l, const YV12_BUFFER_CONFIG *rec,
-                    const YV12_BUFFER_CONFIG *org, const AV1_COMMON *cm,
-                    int block_size, int w, int h, unsigned int strength,
-                    unsigned int fb_size_log2, uint8_t *bit) {
+static int clpf_bit(UNUSED int k, UNUSED int l,
+                    UNUSED const YV12_BUFFER_CONFIG *rec,
+                    UNUSED const YV12_BUFFER_CONFIG *org,
+                    UNUSED const AV1_COMMON *cm, UNUSED int block_size,
+                    UNUSED int w, UNUSED int h, UNUSED unsigned int strength,
+                    UNUSED unsigned int fb_size_log2, uint8_t *bit) {
   return *bit;
 }
 #endif
index 8639add13723ec616d43f71763d3225ccc2334e5..4221505ddda6a006982613125cb853f6fe05eaf7 100644 (file)
@@ -100,7 +100,7 @@ static int clpf_rdo(int y, int x, const YV12_BUFFER_CONFIG *rec,
                     const YV12_BUFFER_CONFIG *org, const AV1_COMMON *cm,
                     unsigned int block_size, unsigned int fb_size_log2, int w,
                     int h, int64_t res[4][4]) {
-  int i, m, n, filtered = 0;
+  int c, m, n, filtered = 0;
   int sum[4];
   int bslog = get_msb(block_size);
   sum[0] = sum[1] = sum[2] = sum[3] = 0;
@@ -153,11 +153,11 @@ static int clpf_rdo(int y, int x, const YV12_BUFFER_CONFIG *rec,
     }
   }
 
-  for (i = 0; i < 4; i++) {
-    res[i][0] += sum[0];
-    res[i][1] += sum[1];
-    res[i][2] += sum[2];
-    res[i][3] += sum[3];
+  for (c = 0; c < 4; c++) {
+    res[c][0] += sum[0];
+    res[c][1] += sum[1];
+    res[c][2] += sum[2];
+    res[c][3] += sum[3];
   }
   return filtered;
 }
@@ -165,7 +165,7 @@ static int clpf_rdo(int y, int x, const YV12_BUFFER_CONFIG *rec,
 void av1_clpf_test_frame(const YV12_BUFFER_CONFIG *rec,
                          const YV12_BUFFER_CONFIG *org, const AV1_COMMON *cm,
                          int *best_strength, int *best_bs) {
-  int i, j, k, l;
+  int c, j, k, l;
   int64_t best, sums[4][4];
   int width = rec->y_crop_width, height = rec->y_crop_height;
   const int bs = MAX_MIB_SIZE;
@@ -213,9 +213,9 @@ void av1_clpf_test_frame(const YV12_BUFFER_CONFIG *rec,
   }
 
   best = (int64_t)1 << 62;
-  for (i = 0; i < 4; i++)
+  for (c = 0; c < 4; c++)
     for (j = 0; j < 4; j++)
-      if ((!i || j) && sums[i][j] < best) best = sums[i][j];
+      if ((!c || j) && sums[c][j] < best) best = sums[c][j];
   best &= 15;
   *best_bs = (best > 3) * (5 + (best < 12) + (best < 8));
   *best_strength = best ? 1 << ((best - 1) & 3) : 0;