• Home
  • Raw
  • Download

Lines Matching refs:channel

43   for (size_t channel = 0; channel < num_channels_; ++channel) {  in Reset()  local
44 channel_parameters_[channel].Reset(); in Reset()
132 size_t channel, in GenerateBackgroundNoise() argument
144 memcpy(noise_samples - kNoiseLpcOrder, FilterState(channel), in GenerateBackgroundNoise()
148 if (ScaleShift(channel) > 1) { in GenerateBackgroundNoise()
149 dc_offset = 1 << (ScaleShift(channel) - 1); in GenerateBackgroundNoise()
154 Scale(channel), dc_offset, in GenerateBackgroundNoise()
155 ScaleShift(channel), num_noise_samples); in GenerateBackgroundNoise()
158 Filter(channel), kNoiseLpcOrder + 1, in GenerateBackgroundNoise()
162 channel, in GenerateBackgroundNoise()
166 int16_t bgn_mute_factor = MuteFactor(channel); in GenerateBackgroundNoise()
173 SetMuteFactor(channel, bgn_mute_factor); in GenerateBackgroundNoise()
180 int32_t BackgroundNoise::Energy(size_t channel) const { in Energy()
181 assert(channel < num_channels_); in Energy()
182 return channel_parameters_[channel].energy; in Energy()
185 void BackgroundNoise::SetMuteFactor(size_t channel, int16_t value) { in SetMuteFactor() argument
186 assert(channel < num_channels_); in SetMuteFactor()
187 channel_parameters_[channel].mute_factor = value; in SetMuteFactor()
190 int16_t BackgroundNoise::MuteFactor(size_t channel) const { in MuteFactor()
191 assert(channel < num_channels_); in MuteFactor()
192 return channel_parameters_[channel].mute_factor; in MuteFactor()
195 const int16_t* BackgroundNoise::Filter(size_t channel) const { in Filter()
196 assert(channel < num_channels_); in Filter()
197 return channel_parameters_[channel].filter; in Filter()
200 const int16_t* BackgroundNoise::FilterState(size_t channel) const { in FilterState()
201 assert(channel < num_channels_); in FilterState()
202 return channel_parameters_[channel].filter_state; in FilterState()
205 void BackgroundNoise::SetFilterState(size_t channel, in SetFilterState() argument
207 assert(channel < num_channels_); in SetFilterState()
209 memcpy(channel_parameters_[channel].filter_state, input.data(), in SetFilterState()
213 int16_t BackgroundNoise::Scale(size_t channel) const { in Scale()
214 assert(channel < num_channels_); in Scale()
215 return channel_parameters_[channel].scale; in Scale()
217 int16_t BackgroundNoise::ScaleShift(size_t channel) const { in ScaleShift()
218 assert(channel < num_channels_); in ScaleShift()
219 return channel_parameters_[channel].scale_shift; in ScaleShift()
236 void BackgroundNoise::IncrementEnergyThreshold(size_t channel, in IncrementEnergyThreshold() argument
243 assert(channel < num_channels_); in IncrementEnergyThreshold()
244 ChannelParameters& parameters = channel_parameters_[channel]; in IncrementEnergyThreshold()
276 void BackgroundNoise::SaveParameters(size_t channel, in SaveParameters() argument
281 assert(channel < num_channels_); in SaveParameters()
282 ChannelParameters& parameters = channel_parameters_[channel]; in SaveParameters()