OpenShot Audio Library | OpenShotAudio  0.3.2
juce_FFT.h
1 /*
2  ==============================================================================
3 
4  This file is part of the JUCE library.
5  Copyright (c) 2017 - ROLI Ltd.
6 
7  JUCE is an open source library subject to commercial or open-source
8  licensing.
9 
10  By using JUCE, you agree to the terms of both the JUCE 5 End-User License
11  Agreement and JUCE 5 Privacy Policy (both updated and effective as of the
12  27th April 2017).
13 
14  End User License Agreement: www.juce.com/juce-5-licence
15  Privacy Policy: www.juce.com/juce-5-privacy-policy
16 
17  Or: You may also use this code under the terms of the GPL v3 (see
18  www.gnu.org/licenses).
19 
20  JUCE IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
21  EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
22  DISCLAIMED.
23 
24  ==============================================================================
25 */
26 
27 namespace juce
28 {
29 namespace dsp
30 {
31 
45 class JUCE_API FFT
46 {
47 public:
48  //==============================================================================
52  FFT (int order);
53 
55  ~FFT();
56 
57  //==============================================================================
61  void perform (const Complex<float>* input, Complex<float>* output, bool inverse) const noexcept;
62 
82  void performRealOnlyForwardTransform (float* inputOutputData,
83  bool dontCalculateNegativeFrequencies = false) const noexcept;
84 
92  void performRealOnlyInverseTransform (float* inputOutputData) const noexcept;
93 
98  void performFrequencyOnlyForwardTransform (float* inputOutputData) const noexcept;
99 
101  int getSize() const noexcept { return size; }
102 
103  //==============================================================================
104  #ifndef DOXYGEN
105  /* internal */
106  struct Instance;
107  template <typename> struct EngineImpl;
108  #endif
109 
110 private:
111  //==============================================================================
112  struct Engine;
113 
114  std::unique_ptr<Instance> engine;
115  int size;
116 
117  //==============================================================================
118  JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (FFT)
119 };
120 
121 } // namespace dsp
122 } // namespace juce
int getSize() const noexcept
Definition: juce_FFT.h:101