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

Side by Side Diff: webrtc/modules/audio_coding/neteq/expand.h

Issue 1172163004: Reformat existing code. There should be no functional effects. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Resync Created 5 years, 6 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 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 int16_t current_voice_mix_factor; /* Q14 */ 112 int16_t current_voice_mix_factor; /* Q14 */
113 AudioVector expand_vector0; 113 AudioVector expand_vector0;
114 AudioVector expand_vector1; 114 AudioVector expand_vector1;
115 bool onset; 115 bool onset;
116 int16_t mute_slope; /* Q20 */ 116 int16_t mute_slope; /* Q20 */
117 }; 117 };
118 118
119 // Calculate the auto-correlation of |input|, with length |input_length| 119 // Calculate the auto-correlation of |input|, with length |input_length|
120 // samples. The correlation is calculated from a downsampled version of 120 // samples. The correlation is calculated from a downsampled version of
121 // |input|, and is written to |output|. The scale factor is written to 121 // |input|, and is written to |output|. The scale factor is written to
122 // |output_scale|. Returns the length of the correlation vector. 122 // |output_scale|.
123 int16_t Correlation(const int16_t* input, size_t input_length, 123 void Correlation(const int16_t* input,
124 int16_t* output, int16_t* output_scale) const; 124 size_t input_length,
125 int16_t* output,
126 int16_t* output_scale) const;
125 127
126 void UpdateLagIndex(); 128 void UpdateLagIndex();
127 129
128 BackgroundNoise* background_noise_; 130 BackgroundNoise* background_noise_;
129 const size_t overlap_length_; 131 const size_t overlap_length_;
130 int16_t max_lag_; 132 int16_t max_lag_;
131 size_t expand_lags_[kNumLags]; 133 size_t expand_lags_[kNumLags];
132 int lag_index_direction_; 134 int lag_index_direction_;
133 int current_lag_index_; 135 int current_lag_index_;
134 bool stop_muting_; 136 bool stop_muting_;
135 rtc::scoped_ptr<ChannelParameters[]> channel_parameters_; 137 rtc::scoped_ptr<ChannelParameters[]> channel_parameters_;
136 138
137 DISALLOW_COPY_AND_ASSIGN(Expand); 139 DISALLOW_COPY_AND_ASSIGN(Expand);
138 }; 140 };
139 141
140 struct ExpandFactory { 142 struct ExpandFactory {
141 ExpandFactory() {} 143 ExpandFactory() {}
142 virtual ~ExpandFactory() {} 144 virtual ~ExpandFactory() {}
143 145
144 virtual Expand* Create(BackgroundNoise* background_noise, 146 virtual Expand* Create(BackgroundNoise* background_noise,
145 SyncBuffer* sync_buffer, 147 SyncBuffer* sync_buffer,
146 RandomVector* random_vector, 148 RandomVector* random_vector,
147 int fs, 149 int fs,
148 size_t num_channels) const; 150 size_t num_channels) const;
149 }; 151 };
150 152
151 } // namespace webrtc 153 } // namespace webrtc
152 #endif // WEBRTC_MODULES_AUDIO_CODING_NETEQ_EXPAND_H_ 154 #endif // WEBRTC_MODULES_AUDIO_CODING_NETEQ_EXPAND_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698