BaseAudioContext.createConstantSource()

The createConstantSource() property of the BaseAudioContext interface creates a ConstantSourceNode object, which is an audio source that continuously outputs a monaural (one-channel) sound signal whose samples all have the same value.

Note: The ConstantSourceNode() constructor is the recommended way to create a ConstantSourceNode; see Creating an AudioNode.

Syntax

var constantSourceNode = AudioContext.createConstantSource()

Parameters

None.

Returns

A ConstantSourceNode instance.

Specifications

Browser compatibility

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari WebView Android Chrome Android Firefox for Android Opera Android Safari on IOS Samsung Internet
createConstantSource
56
79
52
No
43
14.1
56
56
52
43
14.5
6.0

© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/BaseAudioContext/createConstantSource