Chromium Code Reviews| Index: webrtc/common_audio/lapped_transform_unittest.cc |
| diff --git a/webrtc/common_audio/lapped_transform_unittest.cc b/webrtc/common_audio/lapped_transform_unittest.cc |
| index f688cc240a198d5d40b9e56f4cf5ed30001163f3..eb1c80f28101335b51e1d42459472b2fb5e72c8f 100644 |
| --- a/webrtc/common_audio/lapped_transform_unittest.cc |
| +++ b/webrtc/common_audio/lapped_transform_unittest.cc |
| @@ -36,12 +36,12 @@ class NoopCallback : public webrtc::LappedTransform::Callback { |
| ++block_num_; |
| } |
| - int block_num() { |
| + size_t block_num() { |
| return block_num_; |
| } |
| private: |
| - int block_num_; |
| + size_t block_num_; |
| }; |
| class FftCheckerCallback : public webrtc::LappedTransform::Callback { |
| @@ -69,12 +69,12 @@ class FftCheckerCallback : public webrtc::LappedTransform::Callback { |
| } |
| } |
| - int block_num() { |
| + size_t block_num() { |
| return block_num_; |
| } |
| private: |
| - int block_num_; |
| + size_t block_num_; |
| }; |
| void SetFloatArray(float value, int rows, int cols, float* const* array) { |
| @@ -91,9 +91,9 @@ namespace webrtc { |
| TEST(LappedTransformTest, Windowless) { |
| const int kChannels = 3; |
|
tlegrand-webrtc
2016/01/07 12:47:52
size_t?
|
| - const int kChunkLength = 512; |
| - const int kBlockLength = 64; |
| - const int kShiftAmount = 64; |
| + const size_t kChunkLength = 512; |
| + const size_t kBlockLength = 64; |
| + const size_t kShiftAmount = 64; |
| NoopCallback noop; |
| // Rectangular window. |
| @@ -119,7 +119,7 @@ TEST(LappedTransformTest, Windowless) { |
| trans.ProcessChunk(in_chunk, out_chunk); |
| for (int i = 0; i < kChannels; ++i) { |
| - for (int j = 0; j < kChunkLength; ++j) { |
| + for (size_t j = 0; j < kChunkLength; ++j) { |
| ASSERT_NEAR(out_chunk[i][j], 2.0f, 1e-5f); |
| } |
| } |
| @@ -128,9 +128,9 @@ TEST(LappedTransformTest, Windowless) { |
| } |
| TEST(LappedTransformTest, IdentityProcessor) { |
| - const int kChunkLength = 512; |
| - const int kBlockLength = 64; |
| - const int kShiftAmount = 32; |
| + const size_t kChunkLength = 512; |
| + const size_t kBlockLength = 64; |
| + const size_t kShiftAmount = 32; |
| NoopCallback noop; |
| // Identity window for |overlap = block_size / 2|. |
| @@ -149,7 +149,7 @@ TEST(LappedTransformTest, IdentityProcessor) { |
| trans.ProcessChunk(&in_chunk, &out_chunk); |
| - for (int i = 0; i < kChunkLength; ++i) { |
| + for (size_t i = 0; i < kChunkLength; ++i) { |
| ASSERT_NEAR(out_chunk[i], |
| (i < kBlockLength - kShiftAmount) ? 0.0f : 2.0f, |
| 1e-5f); |
| @@ -159,8 +159,8 @@ TEST(LappedTransformTest, IdentityProcessor) { |
| } |
| TEST(LappedTransformTest, Callbacks) { |
| - const int kChunkLength = 512; |
| - const int kBlockLength = 64; |
| + const size_t kChunkLength = 512; |
| + const size_t kBlockLength = 64; |
| FftCheckerCallback call; |
| // Rectangular window. |
| @@ -183,7 +183,7 @@ TEST(LappedTransformTest, Callbacks) { |
| } |
| TEST(LappedTransformTest, chunk_length) { |
| - const int kBlockLength = 64; |
| + const size_t kBlockLength = 64; |
| FftCheckerCallback call; |
| const float window[kBlockLength] = {}; |