Listener
The Listener represents the position and orientation of the player. It is accessed via world.listener and is used for spatialization, occlusion rays, and reflection simulation.
Methods
Section titled “Methods”setCamera(camera)
Section titled “setCamera(camera)”listener.setCamera(camera: Camera | null): voidSets the Three.js render camera used by perspective correction. Call it after the
camera’s projection matrix or world matrix changes. Passing null disables the
camera-dependent correction while leaving simulation unchanged. XR array cameras
are ignored unless world was created with perspectiveCorrection.applyInXR.
setPosition(position)
Section titled “setPosition(position)”listener.setPosition(position: Vector3Like): voidSets the listener position in world space.
setOrientation(orientation)
Section titled “setOrientation(orientation)”listener.setOrientation(orientation: QuaternionLike): voidSets the listener orientation as a quaternion.
setTransform(position, orientation)
Section titled “setTransform(position, orientation)”listener.setTransform( position: Vector3Like, orientation: QuaternionLike,): voidSets both position and orientation in one call, then updates the simulator and reflection worker.
setReverb(settings)
Section titled “setReverb(settings)”listener.setReverb(settings: false | ReverbSettings): voidEnables or disables listener-centric reverb. Requires the world to have been created with reflections enabled.
ReverbSettings
Section titled “ReverbSettings”reverbScale
: ThreeBand — per-band reverb scale. Default: [1, 1, 1].