refDistance
Summary
A reference distance for reducing volume as source moves further from the listener. The default value is 1.
Property of apis/webaudio/PannerNodeapis/webaudio/PannerNode
Syntax
var result = PannerNode.refDistance;
PannerNode.refDistance = value;
Return Value
Returns an object of type NumberNumber
Examples
var audioCtx = new AudioContext();
var panner = audioCtx.createPanner();
panner.refDistance = 1;
Related specifications
- W3C Web Audio API
- W3C Editor’s Draft