Audacity 3.2.0
Classes | Typedefs | Functions
PowerSpectrumGetter.h File Reference
#include <memory>
#include <type_traits>
#include <vector>
#include "pffft.h"
Include dependency graph for PowerSpectrumGetter.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  PffftSetupDeleter
 
struct  PffftAllocatorBase
 
struct  PffftAllocator< T >
 Aligned memory is required by pffft, so this defines an allocator. More...
 
struct  PffftAllocator< T >::rebind< U >
 
struct  PffftAlignedCount
 
struct  PffftFloats
 A pointer to an aligned range of floats. More...
 
struct  PffftConstFloats
 A read-only pointer to an aligned range of floats. More...
 
struct  PffftFloatVector
 A vector of floats guaranteeing alignment as demanded by pffft. More...
 
class  PowerSpectrumGetter
 Much faster that FFT.h's PowerSpectrum, at least in Short-Time Fourier Transform-like situations, where many power spectra of the same size are needed. Currently only power spectrum, but may be generalized to other uses. More...
 

Typedefs

using PffftSetupHolder = std::unique_ptr< PFFFT_Setup, PffftSetupDeleter >
 

Functions

template<typename Integral >
auto operator* (PffftAlignedCount x, Integral y) -> std::enable_if_t< std::is_unsigned_v< Integral > &&sizeof(Integral)<=sizeof(size_t), PffftAlignedCount >
 
template<typename Integral >
auto operator* (Integral x, PffftAlignedCount y) -> std::enable_if_t< std::is_unsigned_v< Integral > &&sizeof(Integral)<=sizeof(size_t), PffftAlignedCount >
 

Typedef Documentation

◆ PffftSetupHolder

using PffftSetupHolder = std::unique_ptr<PFFFT_Setup, PffftSetupDeleter>

Definition at line 25 of file PowerSpectrumGetter.h.

Function Documentation

◆ operator*() [1/2]

template<typename Integral >
auto operator* ( Integral  x,
PffftAlignedCount  y 
) -> std::enable_if_t< std::is_unsigned_v<Integral> && sizeof(Integral) <= sizeof(size_t), PffftAlignedCount>
inline

Definition at line 88 of file PowerSpectrumGetter.h.

92{
93 return PffftAlignedCount(x * static_cast<size_t>(y));
94}

◆ operator*() [2/2]

template<typename Integral >
auto operator* ( PffftAlignedCount  x,
Integral  y 
) -> std::enable_if_t< std::is_unsigned_v<Integral> && sizeof(Integral) <= sizeof(size_t), PffftAlignedCount>
inline

Definition at line 79 of file PowerSpectrumGetter.h.

83{
84 return PffftAlignedCount(static_cast<size_t>(x) * y);
85}

Referenced by MemoryStream::Iterator::operator->().

Here is the caller graph for this function: