Index: webrtc/common_audio/smoothing_filter.h |
diff --git a/webrtc/common_audio/smoothing_filter.h b/webrtc/common_audio/smoothing_filter.h |
index 64a83d14848ae6200edefd4a6d6e271feac12242..03eb718d54f05c3c2df7d30ae5984a4ef2443ae8 100644 |
--- a/webrtc/common_audio/smoothing_filter.h |
+++ b/webrtc/common_audio/smoothing_filter.h |
@@ -23,6 +23,7 @@ class SmoothingFilter { |
virtual ~SmoothingFilter() = default; |
virtual void AddSample(float sample) = 0; |
virtual rtc::Optional<float> GetAverage() const = 0; |
+ virtual void SetTimeConstantMs(int time_constant_ms) = 0; |
}; |
// SmoothingFilterImpl applies an exponential filter |
@@ -35,9 +36,10 @@ class SmoothingFilterImpl final : public SmoothingFilter { |
void AddSample(float sample) override; |
rtc::Optional<float> GetAverage() const override; |
+ void SetTimeConstantMs(int time_constant_ms) override; |
private: |
- const int time_constant_ms_; |
+ int time_constant_ms_; |
const Clock* const clock_; |
bool first_sample_received_; |