diff --git a/lib/bom.js b/lib/bom.js index 0f1eed349fc..ecbc8a22010 100644 --- a/lib/bom.js +++ b/lib/bom.js @@ -699,6 +699,7 @@ declare class BaseAudioContext { createBiquadFilter(): BiquadFilterNode; createChannelMerger(numberOfInputs?: number): ChannelMergerNode; createChannelSplitter(numberOfInputs?: number): ChannelSplitterNode; + createConstantSource(): ConstantSourceNode; createConvolver(): ConvolverNode; createDelay(maxDelayTime?: number): DelayNode; createDynamicsCompressor(): DynamicsCompressorNode; @@ -904,6 +905,18 @@ declare class BiquadFilterNode extends AudioNode { declare class ChannelMergerNode extends AudioNode {} declare class ChannelSplitterNode extends AudioNode {} + +type ConstantSourceOptions = { + offset?: number; +} +declare class ConstantSourceNode extends AudioNode { + constructor(context: BaseAudioContext, options?: ConstantSourceOptions): ConstantSourceNode; + offset: AudioParam; + onended: (ev: any) => any; + start(when?: number): void; + stop(when?: number): void; +} + declare class ConvolverNode extends AudioNode { buffer: AudioBuffer; normalize: bool;