Skip to main content

AudioGraphContext

Context handed to an AudioGraphBuilder each time a SoundTrack starts or resumes The builder is responsible for connecting source to destination through any Web Audio nodes it likes (panners, filters, convolvers, analysers...).

Index

Properties

readonlyaudioContext

audioContext: AudioContext

The shared AudioContext for this engine, use it to create effect nodes.

readonlybufferSource

bufferSource: AudioBufferSourceNode

The single-use AudioBufferSourceNode feeding source. It is fully configured (buffer, loop, playbackRate, detune) but not yet started, so you may schedule automation on its params. It is already connected to source; do not connect it anywhere else.

readonlydestination

destination: AudioNode

The Sound's output node (a GainNode that carries Sound.volume and is connected onwards to the speakers or a SoundManager). Anything you wire must eventually reach this node or the track will be silent.

readonlysource

source: AudioNode

The track's audio: the buffer source already routed through the track's own volume gain. Connect this (not bufferSource) to destination, or the per-play volume is bypassed. Excalibur disconnects it each time the track restarts or stops.

readonlytrack

track: SoundTrack

The SoundTrack being (re)started, useful for correlation (e.g. as a WeakMap key for per-track effect state) and runtime reads.