ISSUE-21803: implement ConstantSourceNode audionode

This commit is contained in:
Thomas Delacour 2019-08-02 08:50:07 -04:00 committed by Thomas Delacour
parent 18c500ecc8
commit 6027dd148a
18 changed files with 238 additions and 159 deletions

View file

@ -31,7 +31,7 @@ interface BaseAudioContext : EventTarget {
optional DecodeSuccessCallback successCallback,
optional DecodeErrorCallback errorCallback);
[Throws] AudioBufferSourceNode createBufferSource();
// ConstantSourceNode createConstantSource();
[Throws] ConstantSourceNode createConstantSource();
// ScriptProcessorNode createScriptProcessor(optional unsigned long bufferSize = 0,
// optional unsigned long numberOfInputChannels = 2,
// optional unsigned long numberOfOutputChannels = 2);

View file

@ -0,0 +1,17 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
/*
* The origin of this IDL file is
* https://webaudio.github.io/web-audio-api/#ConstantSourceNode
*/
dictionary ConstantSourceOptions: AudioNodeOptions {
float offset = 1;
};
[Exposed=Window,
Constructor (BaseAudioContext context, optional ConstantSourceOptions options = {})]
interface ConstantSourceNode : AudioScheduledSourceNode {
readonly attribute AudioParam offset;
};