mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-07-23 09:43:53 +02:00
remove debug
This commit is contained in:
parent
bffc1a38a7
commit
e46a820872
1 changed files with 1 additions and 2 deletions
|
@ -39,7 +39,7 @@ void AudioNoiseGate::removeDCOffset(int16_t* samples, int numSamples) {
|
||||||
//
|
//
|
||||||
// Measure the DC offset over a trailing number of frames, and remove it from the input signal.
|
// Measure the DC offset over a trailing number of frames, and remove it from the input signal.
|
||||||
// This causes the noise background measurements and server muting to be more accurate. Many off-board
|
// This causes the noise background measurements and server muting to be more accurate. Many off-board
|
||||||
// ADC's have a noticeable DC offset.
|
// ADC's have a noticeable DC offset.
|
||||||
//
|
//
|
||||||
const float DC_OFFSET_AVERAGING = 0.99f;
|
const float DC_OFFSET_AVERAGING = 0.99f;
|
||||||
float measuredDcOffset = 0.0f;
|
float measuredDcOffset = 0.0f;
|
||||||
|
@ -47,7 +47,6 @@ void AudioNoiseGate::removeDCOffset(int16_t* samples, int numSamples) {
|
||||||
for (int i = 0; i < numSamples; i++) {
|
for (int i = 0; i < numSamples; i++) {
|
||||||
measuredDcOffset += samples[i];
|
measuredDcOffset += samples[i];
|
||||||
samples[i] -= (int16_t) _dcOffset;
|
samples[i] -= (int16_t) _dcOffset;
|
||||||
//samples[i] = 0;
|
|
||||||
}
|
}
|
||||||
// Update measured DC offset
|
// Update measured DC offset
|
||||||
measuredDcOffset /= numSamples;
|
measuredDcOffset /= numSamples;
|
||||||
|
|
Loading…
Reference in a new issue