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

Side by Side Diff: webrtc/modules/audio_processing/test/test_utils.cc

Issue 1335923002: Add RTC_ prefix to (D)CHECKs and related macros. (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) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 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 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 return AudioProcessing::kStereo; 93 return AudioProcessing::kStereo;
94 default: 94 default:
95 assert(false); 95 assert(false);
96 return AudioProcessing::kMono; 96 return AudioProcessing::kMono;
97 } 97 }
98 } 98 }
99 99
100 std::vector<Point> ParseArrayGeometry(const std::string& mic_positions, 100 std::vector<Point> ParseArrayGeometry(const std::string& mic_positions,
101 size_t num_mics) { 101 size_t num_mics) {
102 const std::vector<float> values = ParseList<float>(mic_positions); 102 const std::vector<float> values = ParseList<float>(mic_positions);
103 CHECK_EQ(values.size(), 3 * num_mics) << 103 RTC_CHECK_EQ(values.size(), 3 * num_mics)
104 "Could not parse mic_positions or incorrect number of points."; 104 << "Could not parse mic_positions or incorrect number of points.";
105 105
106 std::vector<Point> result; 106 std::vector<Point> result;
107 result.reserve(num_mics); 107 result.reserve(num_mics);
108 for (size_t i = 0; i < values.size(); i += 3) { 108 for (size_t i = 0; i < values.size(); i += 3) {
109 double x = values[i + 0]; 109 double x = values[i + 0];
110 double y = values[i + 1]; 110 double y = values[i + 1];
111 double z = values[i + 2]; 111 double z = values[i + 2];
112 result.push_back(Point(x, y, z)); 112 result.push_back(Point(x, y, z));
113 } 113 }
114 114
115 return result; 115 return result;
116 } 116 }
117 117
118 118
119 } // namespace webrtc 119 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_processing/test/audioproc_float.cc ('k') | webrtc/modules/audio_processing/three_band_filter_bank.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698