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

Side by Side Diff: webrtc/voice_engine/level_indicator.cc

Issue 2230823004: Added a level indicator to new mixer. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@mixer_gn_fixes
Patch Set: Made local variable const. Created 4 years, 4 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
« no previous file with comments | « webrtc/modules/audio_mixer/test/audio_mixer_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 10 matching lines...) Expand all
21 // in the range of 0-32 21 // in the range of 0-32
22 const int8_t permutation[33] = 22 const int8_t permutation[33] =
23 {0,1,2,3,4,4,5,5,5,5,6,6,6,6,6,7,7,7,7,8,8,8,9,9,9,9,9,9,9,9,9,9,9}; 23 {0,1,2,3,4,4,5,5,5,5,6,6,6,6,6,7,7,7,7,8,8,8,9,9,9,9,9,9,9,9,9,9,9};
24 24
25 25
26 AudioLevel::AudioLevel() : 26 AudioLevel::AudioLevel() :
27 _absMax(0), 27 _absMax(0),
28 _count(0), 28 _count(0),
29 _currentLevel(0), 29 _currentLevel(0),
30 _currentLevelFullRange(0) { 30 _currentLevelFullRange(0) {
31 WebRtcSpl_Init();
31 } 32 }
32 33
33 AudioLevel::~AudioLevel() { 34 AudioLevel::~AudioLevel() {
34 } 35 }
35 36
36 void AudioLevel::Clear() 37 void AudioLevel::Clear()
37 { 38 {
38 rtc::CritScope cs(&_critSect); 39 rtc::CritScope cs(&_critSect);
39 _absMax = 0; 40 _absMax = 0;
40 _count = 0; 41 _count = 0;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 92
92 int16_t AudioLevel::LevelFullRange() const 93 int16_t AudioLevel::LevelFullRange() const
93 { 94 {
94 rtc::CritScope cs(&_critSect); 95 rtc::CritScope cs(&_critSect);
95 return _currentLevelFullRange; 96 return _currentLevelFullRange;
96 } 97 }
97 98
98 } // namespace voe 99 } // namespace voe
99 100
100 } // namespace webrtc 101 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_mixer/test/audio_mixer_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698