...
A cascade of second order 5 multiply recursive filters. The module is designed to operate on multiple channels and applies the different coefficients on each channel. The state array is allocated to contain 2*numChannels*numStages values. Each 2nd order section implements the difference equation: $y y[n]=b_0x[n]+b_1x[n-1]+b_2x[n-2]-a_1y[n-1]-a_2y[n-2]
. $ The filter coefficients are stored in the matrix .coeffs. This matrix is of dimension (5*numStages) x numChannels and each 5 x numChannels submatrix corresponds to an individual 2nd order Biquad stage. Within each column, the coefficients are ordered as: [b0; b1; b2; a1; a2].
...
Code Block |
---|
typedef struct _ModuleBiquadNCascade { ModuleInstanceDescriptor instance; // Common Audio Weaver module instance structure INT32 numStages; // Number of stages in the filter. The filter order = 2*numStages. FLOAT32* coeffs; // Matrix of filter coefficients. The size of the matrix is (5*numStages) x numChannels. Each column contains the variables for a biquad arranged as [b0; b1; b2; a1; a2]. FLOAT32* state; // State variables. 2 per channel. void * hardware_specific_struct_pointer; // Usually NULL, but for optimizations that use 3rd party optimizations (like ne10), this may point to the required instance structure } ModuleBiquadNCascadeClass; |
Variables
Properties
Name | Type | Usage | isHidden | Default value | Range | Units |
numStages | int | const | 0 | 1 | 1:1:32 | |
coeffs | float* | parameter | 0 | [5 x 1] | Unrestricted | |
state | float* | state | 1 | [2 x 1] | Unrestricted | |
hardware_specific_struct_pointer | void * | state | 1 | Unrestricted |
Pins
Input Pins
Name: in
Description: audio input
...