Skip to content
Related Articles

Related Articles

Web Audio API | AudioContext outputLatency property

View Discussion
Improve Article
Save Article
Like Article
  • Last Updated : 19 Jul, 2019

The AudioContext interface has a outputLatency property which provides an approximation of the latency in output of the current audio context. This time is between the browser requesting to the host system to start a buffer and the time at which the first sample in the buffer is actually processed by the audio output device.


var latency = audioCtx.outputLatency;

Return Value:

A double value is returned in seconds

Example 1:

<!DOCTYPE html>
        AudioContext outputLatency property
        <h1 style="color:green">
        <h2>AudioContext outputLatency property</h2>
            const audioCtx = new AudioContext();



Supported Browsers:

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!