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

Side by Side Diff: webrtc/modules/audio_processing/high_pass_filter_impl.h

Issue 2415403002: Introduced the new parameter setting scheme for activating the high-pass filter in APM (Closed)
Patch Set: Changes in response to reviewer comments Created 4 years 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
(Empty)
1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 *
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
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
11 #ifndef WEBRTC_MODULES_AUDIO_PROCESSING_HIGH_PASS_FILTER_IMPL_H_
12 #define WEBRTC_MODULES_AUDIO_PROCESSING_HIGH_PASS_FILTER_IMPL_H_
13
14 #include <memory>
15 #include <vector>
16
17 #include "webrtc/base/constructormagic.h"
18 #include "webrtc/base/criticalsection.h"
19 #include "webrtc/modules/audio_processing/include/audio_processing.h"
20
21 namespace webrtc {
22
23 class AudioBuffer;
24
25 class HighPassFilterImpl : public HighPassFilter {
26 public:
27 explicit HighPassFilterImpl(rtc::CriticalSection* crit);
28 ~HighPassFilterImpl() override;
29
30 // TODO(peah): Fold into ctor, once public API is removed.
31 void Initialize(size_t channels, int sample_rate_hz);
32 void ProcessCaptureAudio(AudioBuffer* audio);
33
34 // HighPassFilter implementation.
35 int Enable(bool enable) override;
36 bool is_enabled() const override;
37
38 private:
39 class BiquadFilter;
40 rtc::CriticalSection* const crit_ = nullptr;
41 bool enabled_ GUARDED_BY(crit_) = false;
42 std::vector<std::unique_ptr<BiquadFilter>> filters_ GUARDED_BY(crit_);
43 RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(HighPassFilterImpl);
44 };
45 } // namespace webrtc
46
47 #endif // WEBRTC_MODULES_AUDIO_PROCESSING_HIGH_PASS_FILTER_IMPL_H_
OLDNEW
« no previous file with comments | « webrtc/modules/audio_processing/audio_processing_unittest.cc ('k') | webrtc/modules/audio_processing/high_pass_filter_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698