Skip to main content

Interface: PlayOptions

Defined in: packages/webxr-environment/src/audio.ts:138

Per-play overrides. Everything here beats the cue's own value.

Properties

PropertyModifierTypeDescriptionDefined in
at?readonlyVec3Where in the world it comes from. Implies positional playback.packages/webxr-environment/src/audio.ts:142
facing?readonlyVec3Which way it faces: the direction the sound TRAVELS, as [x, y, z]. The same convention as KeyLightSpec.direction, and for the same reason - one rule for direction across the package, and the hosts' own ideas of forward (three.js audio points along +Z) absorbed by the adapters. Only meaningful with a cue that has a cone. A zero-length vector, or none at all, leaves the sound pointing wherever the host puts it.packages/webxr-environment/src/audio.ts:153
gain?readonlynumberExtra trim for this play, multiplied in. Default 1.packages/webxr-environment/src/audio.ts:140
loop?readonlybooleanOverride the cue's loop.packages/webxr-environment/src/audio.ts:155