OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef IIRProcessor_h | 5 #ifndef IIRProcessor_h |
6 #define IIRProcessor_h | 6 #define IIRProcessor_h |
7 | 7 |
| 8 #include <memory> |
8 #include "modules/webaudio/AudioNode.h" | 9 #include "modules/webaudio/AudioNode.h" |
9 #include "platform/audio/AudioDSPKernel.h" | 10 #include "platform/audio/AudioDSPKernel.h" |
10 #include "platform/audio/AudioDSPKernelProcessor.h" | 11 #include "platform/audio/AudioDSPKernelProcessor.h" |
11 #include "platform/audio/IIRFilter.h" | 12 #include "platform/audio/IIRFilter.h" |
12 #include <memory> | |
13 | 13 |
14 namespace blink { | 14 namespace blink { |
15 | 15 |
16 class IIRDSPKernel; | 16 class IIRDSPKernel; |
17 | 17 |
18 class IIRProcessor final : public AudioDSPKernelProcessor { | 18 class IIRProcessor final : public AudioDSPKernelProcessor { |
19 public: | 19 public: |
20 IIRProcessor(float sampleRate, | 20 IIRProcessor(float sampleRate, |
21 size_t numberOfChannels, | 21 size_t numberOfChannels, |
22 const Vector<double>& feedforwardCoef, | 22 const Vector<double>& feedforwardCoef, |
(...skipping 20 matching lines...) Expand all Loading... |
43 // The feedback and feedforward filter coefficients for the IIR filter. | 43 // The feedback and feedforward filter coefficients for the IIR filter. |
44 AudioDoubleArray m_feedback; | 44 AudioDoubleArray m_feedback; |
45 AudioDoubleArray m_feedforward; | 45 AudioDoubleArray m_feedforward; |
46 // This holds the IIR kernel for computing the frequency response. | 46 // This holds the IIR kernel for computing the frequency response. |
47 std::unique_ptr<IIRDSPKernel> m_responseKernel; | 47 std::unique_ptr<IIRDSPKernel> m_responseKernel; |
48 }; | 48 }; |
49 | 49 |
50 } // namespace blink | 50 } // namespace blink |
51 | 51 |
52 #endif // IIRProcessor_h | 52 #endif // IIRProcessor_h |
OLD | NEW |