Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
dsp::WindowingFunction< FloatType > Class Template Reference

A class which provides multiple windowing functions useful for filter design and spectrum analyzers. More...

#include <juce_Windowing.h>

Public Types

enum  WindowingMethod {
  rectangular = 0 , triangular , hann , hamming ,
  blackman , blackmanHarris , flatTop , kaiser ,
  numWindowingMethods
}
 The windowing methods available. More...
 

Public Member Functions

 WindowingFunction (size_t size, WindowingMethod, bool normalise=true, FloatType beta=0)
 This constructor automatically fills a buffer of the specified size using the fillWindowingTables function and the specified arguments.
 
void fillWindowingTables (size_t size, WindowingMethod type, bool normalise=true, FloatType beta=0) noexcept
 Fills the content of the object array with a given windowing method table.
 
void multiplyWithWindowingTable (FloatType *samples, size_t size) const noexcept
 Multiplies the content of a buffer with the given window.
 

Static Public Member Functions

static void fillWindowingTables (FloatType *samples, size_t size, WindowingMethod, bool normalise=true, FloatType beta=0) noexcept
 Fills the content of an array with a given windowing method table.
 
static const char * getWindowingMethodName (WindowingMethod) noexcept
 Returns the name of a given windowing method.
 

Detailed Description

template<typename FloatType>
class dsp::WindowingFunction< FloatType >

A class which provides multiple windowing functions useful for filter design and spectrum analyzers.

The different functions provided here can be used by creating either a WindowingFunction object, or a static function to fill an array with the windowing method samples.

Member Enumeration Documentation

◆ WindowingMethod

template<typename FloatType >
enum dsp::WindowingFunction::WindowingMethod

The windowing methods available.

Enumerator
rectangular 
triangular 
hann 
hamming 
blackman 
blackmanHarris 
flatTop 
kaiser 
numWindowingMethods 

Constructor & Destructor Documentation

◆ WindowingFunction()

template<typename FloatType >
dsp::WindowingFunction< FloatType >::WindowingFunction ( size_t size,
WindowingMethod ,
bool normalise = true,
FloatType beta = 0 )

This constructor automatically fills a buffer of the specified size using the fillWindowingTables function and the specified arguments.

See also
fillWindowingTables

Member Function Documentation

◆ fillWindowingTables() [1/2]

template<typename FloatType >
void dsp::WindowingFunction< FloatType >::fillWindowingTables ( size_t size,
WindowingMethod type,
bool normalise = true,
FloatType beta = 0 )
noexcept

Fills the content of the object array with a given windowing method table.

Parameters
sizethe size of the destination buffer allocated in the object
typethe type of windowing method being used
normaliseif the result must be normalised, creating a DC amplitude response of one
betaan optional argument useful only for Kaiser's method which must be positive and sets the properties of the method (bandwidth and attenuation increases with beta)

◆ fillWindowingTables() [2/2]

template<typename FloatType >
static void dsp::WindowingFunction< FloatType >::fillWindowingTables ( FloatType * samples,
size_t size,
WindowingMethod ,
bool normalise = true,
FloatType beta = 0 )
staticnoexcept

Fills the content of an array with a given windowing method table.

Parameters
samplesthe destination buffer pointer
sizethe size of the destination buffer allocated in the object
normaliseif the result must be normalised, creating a DC amplitude response of one
betaan optional argument useful only for Kaiser's method, which must be positive and sets the properties of the method (bandwidth and attenuation increases with beta)

◆ multiplyWithWindowingTable()

template<typename FloatType >
void dsp::WindowingFunction< FloatType >::multiplyWithWindowingTable ( FloatType * samples,
size_t size ) const
noexcept

Multiplies the content of a buffer with the given window.

◆ getWindowingMethodName()

template<typename FloatType >
static const char * dsp::WindowingFunction< FloatType >::getWindowingMethodName ( WindowingMethod )
staticnoexcept

Returns the name of a given windowing method.


The documentation for this class was generated from the following file:
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram