Replace int with uint32_t for non-negative values
This also fix a few compiler warnings of comparison between signed
and unsigned values.
Change-Id: I1d633f4dfdffff73743dc3f373564056c6d58813
diff --git a/av1/common/mvref_common.h b/av1/common/mvref_common.h
index 80013e6..95fd6ca 100644
--- a/av1/common/mvref_common.h
+++ b/av1/common/mvref_common.h
@@ -276,7 +276,7 @@
int search_col, int block_idx) {
#if CONFIG_REF_MV
(void)search_col;
- (void)block_idx;
+ (void)block_idx;
return candidate->mbmi.mv[which_mv];
#else
return block_idx >= 0 && candidate->mbmi.sb_type < BLOCK_8X8
diff --git a/test/scan_test.cc b/test/scan_test.cc
index 22a6d85..ec2219c 100644
--- a/test/scan_test.cc
+++ b/test/scan_test.cc
@@ -23,15 +23,15 @@
av1_augment_prob(prob, tx1d_size, tx1d_size);
for (int r = 0; r < tx1d_size; ++r) {
for (int c = 0; c < tx1d_size; ++c) {
- const int idx = r * tx1d_size + c;
+ const uint32_t idx = r * tx1d_size + c;
EXPECT_EQ(ref_prob[idx], prob[idx] >> 16);
}
}
- const int mask = (1 << 10) - 1;
+ const uint32_t mask = (1 << 10) - 1;
for (int r = 0; r < tx1d_size; ++r) {
for (int c = 0; c < tx1d_size; ++c) {
- const int idx = r * tx1d_size + c;
+ const uint32_t idx = r * tx1d_size + c;
EXPECT_EQ(idx, mask ^ (prob[r * tx1d_size + c] & mask));
}
}