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

Side by Side Diff: webrtc/modules/audio_coding/main/acm2/audio_coding_module_impl.cc

Issue 1336923002: Remove the preprocessor symbol WEBRTC_CODEC_PCM16 (it was always defined) (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebase 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 997 matching lines...) Expand 10 before | Expand all | Expand 10 after
1008 void AudioCodingImpl::GetDecodingCallStatistics( 1008 void AudioCodingImpl::GetDecodingCallStatistics(
1009 AudioDecodingCallStats* call_stats) const { 1009 AudioDecodingCallStats* call_stats) const {
1010 acm_old_->GetDecodingCallStatistics(call_stats); 1010 acm_old_->GetDecodingCallStatistics(call_stats);
1011 } 1011 }
1012 1012
1013 bool AudioCodingImpl::MapCodecTypeToParameters(int codec_type, 1013 bool AudioCodingImpl::MapCodecTypeToParameters(int codec_type,
1014 std::string* codec_name, 1014 std::string* codec_name,
1015 int* sample_rate_hz, 1015 int* sample_rate_hz,
1016 int* channels) { 1016 int* channels) {
1017 switch (codec_type) { 1017 switch (codec_type) {
1018 #ifdef WEBRTC_CODEC_PCM16
1019 case acm2::ACMCodecDB::kPCM16B: 1018 case acm2::ACMCodecDB::kPCM16B:
1020 *codec_name = "L16"; 1019 *codec_name = "L16";
1021 *sample_rate_hz = 8000; 1020 *sample_rate_hz = 8000;
1022 *channels = 1; 1021 *channels = 1;
1023 break; 1022 break;
1024 case acm2::ACMCodecDB::kPCM16Bwb: 1023 case acm2::ACMCodecDB::kPCM16Bwb:
1025 *codec_name = "L16"; 1024 *codec_name = "L16";
1026 *sample_rate_hz = 16000; 1025 *sample_rate_hz = 16000;
1027 *channels = 1; 1026 *channels = 1;
1028 break; 1027 break;
(...skipping 10 matching lines...) Expand all
1039 case acm2::ACMCodecDB::kPCM16Bwb_2ch: 1038 case acm2::ACMCodecDB::kPCM16Bwb_2ch:
1040 *codec_name = "L16"; 1039 *codec_name = "L16";
1041 *sample_rate_hz = 16000; 1040 *sample_rate_hz = 16000;
1042 *channels = 2; 1041 *channels = 2;
1043 break; 1042 break;
1044 case acm2::ACMCodecDB::kPCM16Bswb32kHz_2ch: 1043 case acm2::ACMCodecDB::kPCM16Bswb32kHz_2ch:
1045 *codec_name = "L16"; 1044 *codec_name = "L16";
1046 *sample_rate_hz = 32000; 1045 *sample_rate_hz = 32000;
1047 *channels = 2; 1046 *channels = 2;
1048 break; 1047 break;
1049 #endif
1050 #if (defined(WEBRTC_CODEC_ISAC) || defined(WEBRTC_CODEC_ISACFX)) 1048 #if (defined(WEBRTC_CODEC_ISAC) || defined(WEBRTC_CODEC_ISACFX))
1051 case acm2::ACMCodecDB::kISAC: 1049 case acm2::ACMCodecDB::kISAC:
1052 *codec_name = "ISAC"; 1050 *codec_name = "ISAC";
1053 *sample_rate_hz = 16000; 1051 *sample_rate_hz = 16000;
1054 *channels = 1; 1052 *channels = 1;
1055 break; 1053 break;
1056 #endif 1054 #endif
1057 #ifdef WEBRTC_CODEC_ISAC 1055 #ifdef WEBRTC_CODEC_ISAC
1058 case acm2::ACMCodecDB::kISACSWB: 1056 case acm2::ACMCodecDB::kISACSWB:
1059 *codec_name = "ISAC"; 1057 *codec_name = "ISAC";
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
1139 *channels = 1; 1137 *channels = 1;
1140 break; 1138 break;
1141 #endif 1139 #endif
1142 default: 1140 default:
1143 FATAL() << "Codec type " << codec_type << " not supported."; 1141 FATAL() << "Codec type " << codec_type << " not supported.";
1144 } 1142 }
1145 return true; 1143 return true;
1146 } 1144 }
1147 1145
1148 } // namespace webrtc 1146 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_coding/main/acm2/acm_codec_database.cc ('k') | webrtc/modules/audio_coding/main/acm2/codec_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698