AudioParam: cancelScheduledValues() method
Baseline Widely available
This feature is well established and works across many devices and browser versions. It’s been available across browsers since April 2021.
The cancelScheduledValues()
method of the AudioParam
Interface cancels all scheduled future changes to the AudioParam
.
Syntax
js
cancelScheduledValues(startTime)
Parameters
startTime
-
A double representing the time (in seconds) after the
AudioContext
was first created after which all scheduled changes will be cancelled.
Return value
A reference to this AudioParam
object. In some older implementations this
method returns undefined
.
Examples
js
const gainNode = audioCtx.createGain();
gainNode.gain.setValueCurveAtTime(waveArray, audioCtx.currentTime, 2); //'gain' is the AudioParam
gainNode.gain.cancelScheduledValues(audioCtx.currentTime);
Specifications
Specification |
---|
Web Audio API # dom-audioparam-cancelscheduledvalues |
Browser compatibility
Report problems with this compatibility data on GitHubdesktop | mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
cancelScheduledValues |
Legend
Tip: you can click/tap on a cell for more information.
- Full support
- Full support
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.