[audioworklet] AudioWorkletProcessor is missing options for constructor
https://developer.mozilla.org/en-US/docs/Web/API/AudioWorkletProcessor/AudioWorkletProcessor
interface AudioWorkletNodeOptions {
/** @default 1 */
numberOfInputs?: number
/** @default 1 */
numberOfOutputs?: number
outputChannelCount?: number[]
parameterData?: any
processorOptions?: any
}
Parameters
options
: An object that is passed as options parameter to the {{domxref("AudioWorkletNode.AudioWorkletNode", "AudioWorkletNode constructor")}} and passed through the structured clone algorithm. Available properties are as follows:
numberOfInputs{{optional_inline}}
- : The value to initialize the {{domxref("AudioNode.numberOfInputs", "numberOfInputs")}} property to. Defaults to 1.
numberOfOutputs{{optional_inline}}
- : The value to initialize the {{domxref("AudioNode.numberOfOutputs", "numberOfOutputs")}} property to. Defaults to 1.
outputChannelCount{{optional_inline}}
- : An array defining the number of channels for each output. For example, outputChannelCount: [n, m] specifies the number of channels in the first output to be n and the second output to be m. The array length must match
numberOfOutputs.parameterData{{optional_inline}}
- : An object containing the initial values of custom {{domxref("AudioParam")}} objects on this node (in its {{domxref("AudioWorkletNode.parameters", "parameters")}} property), with
keybeing the name of a custom parameter andvaluebeing its initial value.processorOptions{{optional_inline}}
- : Any additional data that can be used for custom initialization of the underlying {{domxref("AudioWorkletProcessor")}}.
Note that there are default values for the first two properties, so even if there are no options object passed to the {{domxref("AudioWorkletNode.AudioWorkletNode", "AudioWorkletNode constructor")}}, the options object passed by the node to the
AudioWorkletProcessorconstructor will exist and at minimum havenumberOfInputsandnumberOfOutputs.
Oh I see now that the type is provided by the lib.dom.d.ts
Well, the constructor for AudioWorkletProcessor still needs to be fixed :)