Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Side by Side Diff: webrtc/modules/audio_processing/audio_processing_impl.cc

Issue 1362503003: Use suffixed {uint,int}{8,16,32,64}_t types. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: google::int32 Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 580 matching lines...) Expand 10 before | Expand all | Expand 10 after
591 frame->sample_rate_hz_ != kSampleRate48kHz) { 591 frame->sample_rate_hz_ != kSampleRate48kHz) {
592 return kBadSampleRateError; 592 return kBadSampleRateError;
593 } 593 }
594 if (echo_control_mobile_->is_enabled() && 594 if (echo_control_mobile_->is_enabled() &&
595 frame->sample_rate_hz_ > kSampleRate16kHz) { 595 frame->sample_rate_hz_ > kSampleRate16kHz) {
596 LOG(LS_ERROR) << "AECM only supports 16 or 8 kHz sample rates"; 596 LOG(LS_ERROR) << "AECM only supports 16 or 8 kHz sample rates";
597 return kUnsupportedComponentError; 597 return kUnsupportedComponentError;
598 } 598 }
599 599
600 // TODO(ajm): The input and output rates and channels are currently 600 // TODO(ajm): The input and output rates and channels are currently
601 // constrained to be identical in the int16 interface. 601 // constrained to be identical in the int16_t interface.
602 ProcessingConfig processing_config = api_format_; 602 ProcessingConfig processing_config = api_format_;
603 processing_config.input_stream().set_sample_rate_hz(frame->sample_rate_hz_); 603 processing_config.input_stream().set_sample_rate_hz(frame->sample_rate_hz_);
604 processing_config.input_stream().set_num_channels(frame->num_channels_); 604 processing_config.input_stream().set_num_channels(frame->num_channels_);
605 processing_config.output_stream().set_sample_rate_hz(frame->sample_rate_hz_); 605 processing_config.output_stream().set_sample_rate_hz(frame->sample_rate_hz_);
606 processing_config.output_stream().set_num_channels(frame->num_channels_); 606 processing_config.output_stream().set_num_channels(frame->num_channels_);
607 607
608 RETURN_ON_ERR(MaybeInitializeLocked(processing_config)); 608 RETURN_ON_ERR(MaybeInitializeLocked(processing_config));
609 if (frame->samples_per_channel_ != api_format_.input_stream().num_frames()) { 609 if (frame->samples_per_channel_ != api_format_.input_stream().num_frames()) {
610 return kBadDataLengthError; 610 return kBadDataLengthError;
611 } 611 }
(...skipping 630 matching lines...) Expand 10 before | Expand all | Expand 10 after
1242 int err = WriteMessageToDebugFile(); 1242 int err = WriteMessageToDebugFile();
1243 if (err != kNoError) { 1243 if (err != kNoError) {
1244 return err; 1244 return err;
1245 } 1245 }
1246 1246
1247 return kNoError; 1247 return kNoError;
1248 } 1248 }
1249 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP 1249 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP
1250 1250
1251 } // namespace webrtc 1251 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698