Structure used for the state variable filter parameters. More...
#include <juce_StateVariableFilter.h>
Public Types | |
using | Ptr = ReferenceCountedObjectPtr< Parameters > |
The Coefficients structure is ref-counted, so this is a handy type that can be used as a pointer to one. More... | |
using | Type = StateVariableFilterType |
Public Member Functions | |
Parameters ()=default | |
Parameters (const Parameters &o) | |
Parameters & | operator= (const Parameters &o) noexcept |
void | setCutOffFrequency (double sampleRate, NumericType frequency, NumericType resonance=static_cast< NumericType >(1.0/MathConstants< double >::sqrt2)) noexcept |
Sets the cutoff frequency and resonance of the IIR filter. More... | |
Public Attributes | |
NumericType | g = static_cast<NumericType> (std::tan (MathConstants<double>::pi * 200.0 / 44100.0)) |
NumericType | h = static_cast<NumericType> (1.0 / (1.0 + R2 * g + g * g)) |
NumericType | R2 = static_cast<NumericType> (MathConstants<double>::sqrt2) |
Type | type = Type::lowPass |
The type of the IIR filter. More... | |
Structure used for the state variable filter parameters.
@tags{DSP}
using juce::dsp::StateVariableFilter::Parameters< NumericType >::Ptr = ReferenceCountedObjectPtr<Parameters> |
The Coefficients structure is ref-counted, so this is a handy type that can be used as a pointer to one.
using juce::dsp::StateVariableFilter::Parameters< NumericType >::Type = StateVariableFilterType |
|
default |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
Sets the cutoff frequency and resonance of the IIR filter.
Note: The bandwidth of the resonance increases with the value of the parameter. To have a standard 12 dB/octave filter, the value must be set at 1 / sqrt(2).
References juce::dsp::StateVariableFilter::Parameters< NumericType >::g, juce::dsp::StateVariableFilter::Parameters< NumericType >::h, jassert, juce::dsp::StateVariableFilter::Parameters< NumericType >::R2, and juce::Colours::tan.
NumericType juce::dsp::StateVariableFilter::Parameters< NumericType >::g = static_cast<NumericType> (std::tan (MathConstants<double>::pi * 200.0 / 44100.0)) |
NumericType juce::dsp::StateVariableFilter::Parameters< NumericType >::h = static_cast<NumericType> (1.0 / (1.0 + R2 * g + g * g)) |
NumericType juce::dsp::StateVariableFilter::Parameters< NumericType >::R2 = static_cast<NumericType> (MathConstants<double>::sqrt2) |
Type juce::dsp::StateVariableFilter::Parameters< NumericType >::type = Type::lowPass |
The type of the IIR filter.