SynthLab SDK
SynthLab::VA1Filter Class Reference
Inheritance diagram for SynthLab::VA1Filter:
SynthLab::IFilterBase

Public Member Functions

virtual bool reset (double _sampleRate)
 
virtual bool update ()
 update the filter due to changes in the GUI controls and/or modulations More...
 
virtual FilterOutputprocess (double xn)
 Process audio through the filter. Different filters produce different outputs in the FilterOutput's array. More...
 
virtual void setFilterParams (double _fc, double _Q)
 Sets the two parameters of all synth filters. You can add more here if you need to. More...
 
void setAlpha (double _alpha)
 
void setBeta (double _beta)
 
void setCoeffs (VA1Coeffs &_coeffs)
 
void copyCoeffs (VA1Filter &destination)
 
double getFBOutput ()
 

Protected Attributes

FilterOutput output
 
double sampleRate = 44100.0
 current sample rate
 
double halfSamplePeriod = 1.0
 
double fc = 0.0
 
double sn = 0.0
 state variables
 
VA1Coeffs coeffs
 

Member Function Documentation

◆ process()

FilterOutput * SynthLab::VA1Filter::process ( double  xn)
virtual

Process audio through the filter. Different filters produce different outputs in the FilterOutput's array.

Returns
FilterOutput structure containing outputs in pre-defined slots

Implements SynthLab::IFilterBase.

◆ reset()

bool SynthLab::VA1Filter::reset ( double  _sampleRate)
virtual

reset members to initialized state

Implements SynthLab::IFilterBase.

◆ setFilterParams()

void SynthLab::VA1Filter::setFilterParams ( double  _fc,
double  _Q 
)
virtual

Sets the two parameters of all synth filters. You can add more here if you need to.

Parameters
_fcthe center or cutoff frequency of the filter
_Qthe quality factor (damping) of the filter

Implements SynthLab::IFilterBase.

◆ update()

bool SynthLab::VA1Filter::update ( )
virtual

update the filter due to changes in the GUI controls and/or modulations

Returns
true if sucessful, false otherwise

Implements SynthLab::IFilterBase.


The documentation for this class was generated from the following files: