API reference

Every public class, method, and event in @codexo/exojs. Generated from source.

C

classAudioManager

@codexo/exojs / audio / stable

Per-Application owner of the audio mix: three pre-configured AudioBus instances (`master` ← `music` + `sound`), a single AudioListener for spatial audio, and a registry of any extra busses the user constructs. The `AudioContext` is shared process-wide, but each Application owns its own bus subtree, so multiple Applications mix independently. Access it via `app.audio`. Drives the per-frame `_tick()` on the listener and every spatial voice, and propagates visibility-driven mute when AudioManager.muteOnHidden is enabled.

6
props
10
methods
1
events
Import
import { AudioManager } from '@codexo/exojs'

Per-Application owner of the audio mix: three pre-configured AudioBus instances (`master` ← `music` + `sound`), a single AudioListener for spatial audio, and a registry of any extra busses the user constructs.

The `AudioContext` is shared process-wide, but each Application owns its own bus subtree, so multiple Applications mix independently. Access it via `app.audio`. Drives the per-frame `_tick()` on the listener and every spatial voice, and propagates visibility-driven mute when AudioManager.muteOnHidden is enabled.

Constructors 1
new(): AudioManager
Methods 10
_applyVisibility(visible: boolean): void
_registerSpatial(voice: SpatialVoice): void
destroy(): void
getBus(name: string): AudioBus
hasBus(name: string): boolean
open(input: AudioInput): InputVoice
play(source: Playable, options?: PlayOptions): Voice
registerBus(bus: AudioBus): this
unregisterBus(bus: AudioBus): this
update(_delta: Time): void
Properties 6
listener: AudioListener
master: AudioBus
music: AudioBus
sound: AudioBus
locked: boolean
muteOnHidden: boolean
Events 1
onUnlock: Signal<[]>
Source