Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.
public interface AudioProcessor
Custom DSP in Java, the Codename One counterpart of the Web Audio
AudioWorkletProcessor. An AudioProcessorNode calls process once per
render quantum of 128 frames, on the render thread.
The arrays follow the worklet’s layout: inputs[input][channel][frame],
outputs[output][channel][frame] and parameters[param][frame]. An input
with nothing connected has one silent channel. A parameter whose value is
constant for the quantum is an array of length 1; otherwise it has 128
values. Outputs arrive zeroed.
The method runs on the audio thread: it must not block, wait on the EDT or allocate in steady state, or the output glitches. Keep the arrays only for the duration of the call; they are reused.
Methods
public abstract boolean process(float[][][] inputs, float[][][] outputs, float[][] parameters) | Renders one quantum. |
Method details
process
public abstract boolean process(float[][][] inputs, float[][][] outputs, float[][] parameters)Parameters
inputsfloat[][][]- the mixed input of each input, per channel
outputsfloat[][][]- the output to fill, per output and channel
parametersfloat[][]- the value of each declared parameter, in declaration order