The actual worklet class that will do the audio processing of a given AudioFilter

Constructor

new(filterId:Int, bus:Int)

Variables

finalfilterId:Int

The id of the audio fitler this worklet is associated with

@:value(-1)bus:Int = -1

Available on clay web

The bus this filter is attached to (-1 if not attached)

@:value(true)active:Bool = true

Available on clay web

Whether this filter is currently active

bus:Int

Available on clay native, unity

active:Bool

Available on clay native, unity

Methods

numParams():Int

Return the number of parameters this filter has. (automatically generated from fields marked with @param, no need to override it)

process(buffer:AudioFilterBuffer, samples:Int, channels:Int, sampleRate:Float, time:Float):Void

Process audio buffer in place. Override this method to implement custom filtering. CAUTION: this may be called from a background thread

Parameters:

buffer

The audio buffer to process (modify in place, planar layout: one channel after another, not interleaved)

samples

Number of samples per channel

channels

Number of audio channels (1 = mono, 2 = stereo)

sampleRate

Sample rate in Hz

time

Current playback time in seconds