Loading...
Searching...
No Matches
juce::dsp::FIR::Coefficients< NumericType > Struct Template Reference

`#include <juce_FIRFilter.h>`

Inheritance diagram for juce::dsp::FIR::Coefficients< NumericType >:

## Public Types

using | Ptr = ReferenceCountedObjectPtr<Coefficients>
Public Types inherited from juce::dsp::ProcessorState
using | Ptr = ReferenceCountedObjectPtr<ProcessorState>

## Public Member Functions

| Coefficients ()
| Coefficients (size_t size)
| Coefficients (const NumericType *samples, size_t numSamples)
| Coefficients (const Coefficients &)=default
| Coefficients (Coefficients &&)=default
Coefficients & | operator= (const Coefficients &)=default
Coefficients & | operator= (Coefficients &&)=default
size_t | getFilterOrder () const noexcept
double | getMagnitudeForFrequency (double frequency, double sampleRate) const noexcept
void | getMagnitudeForFrequencyArray (double *frequencies, double *magnitudes, size_t numSamples, double sampleRate) const noexcept
double | getPhaseForFrequency (double frequency, double sampleRate) const noexcept
void | getPhaseForFrequencyArray (double *frequencies, double *phases, size_t numSamples, double sampleRate) const noexcept
NumericType * | getRawCoefficients () noexcept
const NumericType * | getRawCoefficients () const noexcept
void | normalise () noexcept
Public Member Functions inherited from juce::ReferenceCountedObject
void | incReferenceCount () noexcept
void | decReferenceCount () noexcept
bool | decReferenceCountWithoutDeleting () noexcept
int | getReferenceCount () const noexcept

## Public Attributes

Array< NumericType > | coefficients

## Additional Inherited Members

Protected Member Functions inherited from juce::ReferenceCountedObject
| ReferenceCountedObject ()=default
| ReferenceCountedObject (const ReferenceCountedObject &) noexcept
| ReferenceCountedObject (ReferenceCountedObject &&) noexcept
ReferenceCountedObject & | operator= (const ReferenceCountedObject &) noexcept
ReferenceCountedObject & | operator= (ReferenceCountedObject &&) noexcept
virtual | ~ReferenceCountedObject ()
void | resetReferenceCount () noexcept

## Detailed Description

template<typename NumericType>
struct juce::dsp::FIR::Coefficients< NumericType >

A set of coefficients for use in an FIRFilter object.

See also
  FIRFilter

Definition at line 213 of file juce_FIRFilter.h.

## Member Typedef Documentation

## Ptr

template<typename NumericType>

using juce::dsp::FIR::Coefficients< NumericType >::Ptr = ReferenceCountedObjectPtr<Coefficients>

The Coefficients structure is ref-counted, so this is a handy type that can be used as a pointer to one.

Definition at line 233 of file juce_FIRFilter.h.

## Constructor & Destructor Documentation

## Coefficients() [1/3]

template<typename NumericType>

juce::dsp::FIR::Coefficients< NumericType >::Coefficients | ( |  | ) |

inline

Creates a null set of coefficients (which will produce silence).

Definition at line 217 of file juce_FIRFilter.h.

## Coefficients() [2/3]

template<typename NumericType>

juce::dsp::FIR::Coefficients< NumericType >::Coefficients | ( | size_t | size | ) |

inline

Creates a null set of coefficients of a given size.

Definition at line 220 of file juce_FIRFilter.h.

## Coefficients() [3/3]

template<typename NumericType>

juce::dsp::FIR::Coefficients< NumericType >::Coefficients | ( | const NumericType * | samples,
|  | size_t | numSamples )

inline

Creates a set of coefficients from an array of samples.

Definition at line 223 of file juce_FIRFilter.h.

## Member Function Documentation

## getFilterOrder()

template<typename NumericType>

size_t juce::dsp::FIR::Coefficients< NumericType >::getFilterOrder | ( |  | ) | const

inline noexcept

Returns the filter order associated with the coefficients.

Definition at line 237 of file juce_FIRFilter.h.

## getMagnitudeForFrequency()

template<typename NumericType>

double juce::dsp::FIR::Coefficients< NumericType >::getMagnitudeForFrequency | ( | double | frequency,
|  | double | sampleRate ) const

noexcept

Returns the magnitude frequency response of the filter for a given frequency and sample rate.

## getMagnitudeForFrequencyArray()

template<typename NumericType>

void juce::dsp::FIR::Coefficients< NumericType >::getMagnitudeForFrequencyArray | ( | double * | frequencies,
|  | double * | magnitudes,
|  | size_t | numSamples,
|  | double | sampleRate ) const

noexcept

Returns the magnitude frequency response of the filter for a given frequency array and sample rate.

## getPhaseForFrequency()

template<typename NumericType>

double juce::dsp::FIR::Coefficients< NumericType >::getPhaseForFrequency | ( | double | frequency,
|  | double | sampleRate ) const

noexcept

Returns the phase frequency response of the filter for a given frequency and sample rate.

## getPhaseForFrequencyArray()

template<typename NumericType>

void juce::dsp::FIR::Coefficients< NumericType >::getPhaseForFrequencyArray | ( | double * | frequencies,
|  | double * | phases,
|  | size_t | numSamples,
|  | double | sampleRate ) const

noexcept

Returns the phase frequency response of the filter for a given frequency array and sample rate.

## getRawCoefficients() [1/2]

template<typename NumericType>

const NumericType * juce::dsp::FIR::Coefficients< NumericType >::getRawCoefficients | ( |  | ) | const

inline noexcept

Returns a raw data pointer to the coefficients.

Definition at line 265 of file juce_FIRFilter.h.

## getRawCoefficients() [2/2]

template<typename NumericType>

NumericType * juce::dsp::FIR::Coefficients< NumericType >::getRawCoefficients | ( |  | ) |

inline noexcept

Returns a raw data pointer to the coefficients.

Definition at line 262 of file juce_FIRFilter.h.

## normalise()

template<typename NumericType>

void juce::dsp::FIR::Coefficients< NumericType >::normalise | ( |  | ) |

noexcept

Scales the values of the FIR filter with the sum of the squared coefficients.

## Member Data Documentation

## coefficients

template<typename NumericType>

Array<NumericType> juce::dsp::FIR::Coefficients< NumericType >::coefficients

The raw coefficients. You should leave these numbers alone unless you really know what you're doing.

Definition at line 275 of file juce_FIRFilter.h.

Referenced by Coefficients(), Coefficients(), Coefficients(), getFilterOrder(), getRawCoefficients(), and getRawCoefficients().

The documentation for this struct was generated from the following file:

- juce_FIRFilter.h