@Generated(value="org.realityforge.webtack")
@JsType(isNative=true,
namespace="<global>",
name="Object")
public class AudioContext
extends BaseAudioContext
onstatechange| Constructor and Description |
|---|
AudioContext()
The AudioContext() constructor creates a new AudioContext object which represents an audio-processing graph, built from audio modules linked together, each represented by an AudioNode.
|
AudioContext(AudioContextOptions contextOptions)
The AudioContext() constructor creates a new AudioContext object which represents an audio-processing graph, built from audio modules linked together, each represented by an AudioNode.
|
| Modifier and Type | Method and Description |
|---|---|
double |
baseLatency()
The baseLatency read-only property of the AudioContext interface returns a double that represents the number of seconds of processing latency incurred by the AudioContext passing an audio buffer from the AudioDestinationNode — i.e.
|
Promise<java.lang.Void> |
close()
The close() method of the AudioContext Interface closes the audio context, releasing any system audio resources that it uses.
|
MediaElementAudioSourceNode |
createMediaElementSource(HTMLMediaElement mediaElement)
For more details about media element audio source nodes, check out the MediaElementAudioSourceNode reference page.
|
MediaStreamAudioDestinationNode |
createMediaStreamDestination()
The MediaStream is created when the node is created and is accessible via the MediaStreamAudioDestinationNode's stream attribute.
|
MediaStreamAudioSourceNode |
createMediaStreamSource(MediaStream mediaStream)
For more details about media stream audio source nodes, check out the MediaStreamAudioSourceNode reference page.
|
MediaStreamTrackAudioSourceNode |
createMediaStreamTrackSource(MediaStreamTrack mediaStreamTrack)
A MediaStreamTrackAudioSourceNode object which acts as a source for audio data found in the specified audio track.
|
AudioTimestamp |
getOutputTimestamp()
The getOutputTimestamp() property of the AudioContext interface returns a new AudioTimestamp object containing two audio timestamp values relating to the current audio context.
|
double |
outputLatency()
The outputLatency read-only property of the AudioContext Interface provides an estimation of the output latency of the current audio context.
|
Promise<java.lang.Void> |
resume()
The resume() method of the AudioContext interface resumes the progression of time in an audio context that has previously been suspended.
|
Promise<java.lang.Void> |
suspend()
The suspend() method of the AudioContext Interface suspends the progression of time in the audio context, temporarily halting audio hardware access and reducing CPU/battery usage in the process — this is useful if you want an application to power down the audio hardware when it will not be using an audio context for a while.
|
audioWorklet, createAnalyser, createBiquadFilter, createBuffer, createBufferSource, createChannelMerger, createChannelMerger, createChannelSplitter, createChannelSplitter, createConstantSource, createConvolver, createDelay, createDelay, createDynamicsCompressor, createGain, createIIRFilter, createIIRFilter, createIIRFilter, createIIRFilter, createOscillator, createPanner, createPeriodicWave, createPeriodicWave, createPeriodicWave, createPeriodicWave, createPeriodicWave, createPeriodicWave, createPeriodicWave, createPeriodicWave, createScriptProcessor, createScriptProcessor, createScriptProcessor, createScriptProcessor, createStereoPanner, createWaveShaper, currentTime, decodeAudioData, decodeAudioData, decodeAudioData, destination, listener, sampleRate, stateaddEventListener, addEventListener, addEventListener, dispatchEvent, removeEventListener, removeEventListener, removeEventListenerassign, create, create, defineProperties, defineProperty, defineProperty, entries, freeze, fromEntries, getOwnPropertyDescriptor, getOwnPropertyDescriptor, getOwnPropertyDescriptors, getOwnPropertyNames, getOwnPropertySymbols, getPrototypeOf, hasOwnProperty, hasOwnProperty, is, isExtensible, isFrozen, isPrototypeOf, isSealed, keys, preventExtensions, propertyIsEnumerable, seal, setPrototypeOf, toString_, valueOf_, valuespublic AudioContext(@Nonnull
AudioContextOptions contextOptions)
public AudioContext()
@JsProperty(name="baseLatency") public double baseLatency()
@JsProperty(name="outputLatency") public double outputLatency()
@Nonnull public Promise<java.lang.Void> close()
@Nonnull public MediaElementAudioSourceNode createMediaElementSource(@Nonnull HTMLMediaElement mediaElement)
@Nonnull public MediaStreamAudioDestinationNode createMediaStreamDestination()
@Nonnull public MediaStreamAudioSourceNode createMediaStreamSource(@Nonnull MediaStream mediaStream)
@Nonnull public MediaStreamTrackAudioSourceNode createMediaStreamTrackSource(@Nonnull MediaStreamTrack mediaStreamTrack)
@Nonnull public AudioTimestamp getOutputTimestamp()
@Nonnull public Promise<java.lang.Void> resume()
@Nonnull public Promise<java.lang.Void> suspend()