Index: webrtc/modules/audio_processing/aec3/suppression_gain_unittest.cc |
diff --git a/webrtc/modules/audio_processing/aec3/suppression_gain_unittest.cc b/webrtc/modules/audio_processing/aec3/suppression_gain_unittest.cc |
index 1fd011f10c83e6aa63293008a82ad2bab7882ecd..9a6521c67b00599b7ddde37a54b714e74be07328 100644 |
--- a/webrtc/modules/audio_processing/aec3/suppression_gain_unittest.cc |
+++ b/webrtc/modules/audio_processing/aec3/suppression_gain_unittest.cc |
@@ -33,7 +33,7 @@ TEST(SuppressionGain, NullOutputGains) { |
.GetGain(E2, R2, N2, false, |
std::vector<std::vector<float>>( |
3, std::vector<float>(kBlockSize, 0.f)), |
- 1, false, &high_bands_gain, nullptr), |
+ false, &high_bands_gain, nullptr), |
""); |
} |
@@ -54,8 +54,7 @@ TEST(SuppressionGain, BasicGainComputation) { |
R2.fill(0.1f); |
N2.fill(100.f); |
for (int k = 0; k < 10; ++k) { |
- suppression_gain.GetGain(E2, R2, N2, false, x, 1, false, &high_bands_gain, |
- &g); |
+ suppression_gain.GetGain(E2, R2, N2, false, x, false, &high_bands_gain, &g); |
} |
std::for_each(g.begin(), g.end(), |
[](float a) { EXPECT_NEAR(1.f, a, 0.001); }); |
@@ -65,25 +64,23 @@ TEST(SuppressionGain, BasicGainComputation) { |
R2.fill(0.1f); |
N2.fill(0.f); |
for (int k = 0; k < 10; ++k) { |
- suppression_gain.GetGain(E2, R2, N2, false, x, 1, false, &high_bands_gain, |
- &g); |
+ suppression_gain.GetGain(E2, R2, N2, false, x, false, &high_bands_gain, &g); |
} |
std::for_each(g.begin(), g.end(), |
[](float a) { EXPECT_NEAR(1.f, a, 0.001); }); |
// Ensure that a strong echo is suppressed. |
- E2.fill(0.1f); |
- R2.fill(100.f); |
+ E2.fill(1000000000.f); |
+ R2.fill(10000000000000.f); |
N2.fill(0.f); |
for (int k = 0; k < 10; ++k) { |
- suppression_gain.GetGain(E2, R2, N2, false, x, 1, false, &high_bands_gain, |
- &g); |
+ suppression_gain.GetGain(E2, R2, N2, false, x, false, &high_bands_gain, &g); |
} |
std::for_each(g.begin(), g.end(), |
[](float a) { EXPECT_NEAR(0.f, a, 0.001); }); |
// Verify the functionality for forcing a zero gain. |
- suppression_gain.GetGain(E2, R2, N2, false, x, 1, true, &high_bands_gain, &g); |
+ suppression_gain.GetGain(E2, R2, N2, false, x, true, &high_bands_gain, &g); |
std::for_each(g.begin(), g.end(), [](float a) { EXPECT_FLOAT_EQ(0.f, a); }); |
EXPECT_FLOAT_EQ(0.f, high_bands_gain); |
} |