Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Scroll Documents: Update page title prefix

Overview

Standard audio weighting filters

Discussion

Implements standard weighting filters used in audio. The module operates on multiple channels and internally uses a BiquadCascade modoule. The .weightingType variable specifies what type of filter is implemented. Allowable values are:

...

When changing filter types, the audio output is muted, the filter's state variables are set to zero and then the coefficients are updated. Once the coefficients are changed, the audio is unmuted.

Type Definition

Code Block
typedef struct _ModuleAudioWeighting
{
    ModuleInstanceDescriptor instance;            // Common Audio Weaver module instance structure
    INT32 weightingType;                          // Selects weighting type
    INT32 numStages;                              // Number of stages in the IIR filter
    FLOAT32* coeffs;                              // Array of precomputed filter coefficients for the specified sampling rate
    awe_modBiquadCascadeInstance *filt; // Cascade of second order Biquad filters
    awe_modMuteUnmuteInstance *mute; // Mutes and unmutes to hide artifacts
} ModuleAudioWeightingClass;

Variables

Properties

Name

Type

Usage

isHidden

Default value

Range

Units

weightingType

int

parameter

0

0

0:7

numStages

int

parameter

1

4

Unrestricted

coeffs

float*

parameter

1

[160 x 1]

Unrestricted

Pins

Input Pins

Name: in

Description: Audio Input

...

Sample rate range: Unrestricted

Complex support: Real

Output Pins

Name: out

Description: audio output

Data type: float

Scratch Pins

Channel count: 1

Block size: 32

...

Block size: 32

Sample rate: 48000

MATLAB Usage

File Name: weighting_module.m

...