| Index: webrtc/common_audio/blocker.cc
|
| diff --git a/webrtc/common_audio/blocker.cc b/webrtc/common_audio/blocker.cc
|
| index 359e881a4ba7313611d6219706c2d22a4ff227d8..78a15d8238f3c21edf4b9000dd6532953ac4277a 100644
|
| --- a/webrtc/common_audio/blocker.cc
|
| +++ b/webrtc/common_audio/blocker.cc
|
| @@ -22,10 +22,10 @@ void AddFrames(const float* const* a,
|
| const float* const* b,
|
| int b_start_index,
|
| size_t num_frames,
|
| - int num_channels,
|
| + size_t num_channels,
|
| float* const* result,
|
| size_t result_start_index) {
|
| - for (int i = 0; i < num_channels; ++i) {
|
| + for (size_t i = 0; i < num_channels; ++i) {
|
| for (size_t j = 0; j < num_frames; ++j) {
|
| result[i][j + result_start_index] =
|
| a[i][j + a_start_index] + b[i][j + b_start_index];
|
| @@ -37,10 +37,10 @@ void AddFrames(const float* const* a,
|
| void CopyFrames(const float* const* src,
|
| size_t src_start_index,
|
| size_t num_frames,
|
| - int num_channels,
|
| + size_t num_channels,
|
| float* const* dst,
|
| size_t dst_start_index) {
|
| - for (int i = 0; i < num_channels; ++i) {
|
| + for (size_t i = 0; i < num_channels; ++i) {
|
| memcpy(&dst[i][dst_start_index],
|
| &src[i][src_start_index],
|
| num_frames * sizeof(dst[i][dst_start_index]));
|
| @@ -51,10 +51,10 @@ void CopyFrames(const float* const* src,
|
| void MoveFrames(const float* const* src,
|
| size_t src_start_index,
|
| size_t num_frames,
|
| - int num_channels,
|
| + size_t num_channels,
|
| float* const* dst,
|
| size_t dst_start_index) {
|
| - for (int i = 0; i < num_channels; ++i) {
|
| + for (size_t i = 0; i < num_channels; ++i) {
|
| memmove(&dst[i][dst_start_index],
|
| &src[i][src_start_index],
|
| num_frames * sizeof(dst[i][dst_start_index]));
|
| @@ -64,8 +64,8 @@ void MoveFrames(const float* const* src,
|
| void ZeroOut(float* const* buffer,
|
| size_t starting_idx,
|
| size_t num_frames,
|
| - int num_channels) {
|
| - for (int i = 0; i < num_channels; ++i) {
|
| + size_t num_channels) {
|
| + for (size_t i = 0; i < num_channels; ++i) {
|
| memset(&buffer[i][starting_idx], 0,
|
| num_frames * sizeof(buffer[i][starting_idx]));
|
| }
|
| @@ -75,9 +75,9 @@ void ZeroOut(float* const* buffer,
|
| // stored in |frames|.
|
| void ApplyWindow(const float* window,
|
| size_t num_frames,
|
| - int num_channels,
|
| + size_t num_channels,
|
| float* const* frames) {
|
| - for (int i = 0; i < num_channels; ++i) {
|
| + for (size_t i = 0; i < num_channels; ++i) {
|
| for (size_t j = 0; j < num_frames; ++j) {
|
| frames[i][j] = frames[i][j] * window[j];
|
| }
|
| @@ -100,8 +100,8 @@ namespace webrtc {
|
|
|
| Blocker::Blocker(size_t chunk_size,
|
| size_t block_size,
|
| - int num_input_channels,
|
| - int num_output_channels,
|
| + size_t num_input_channels,
|
| + size_t num_output_channels,
|
| const float* window,
|
| size_t shift_amount,
|
| BlockerCallback* callback)
|
| @@ -166,8 +166,8 @@ Blocker::Blocker(size_t chunk_size,
|
| // TODO(claguna): Look at using ring buffers to eliminate some copies.
|
| void Blocker::ProcessChunk(const float* const* input,
|
| size_t chunk_size,
|
| - int num_input_channels,
|
| - int num_output_channels,
|
| + size_t num_input_channels,
|
| + size_t num_output_channels,
|
| float* const* output) {
|
| CHECK_EQ(chunk_size, chunk_size_);
|
| CHECK_EQ(num_input_channels, num_input_channels_);
|
|
|