Search e01
One query across the encyclopedia, books, dictionary, papers, Wikidata and the developer library. Every hit carries its source.
6 results across 6 corpora for AudioPlaybackStats.
Developer library 6
AudioPlaybackStats
Web Audio API The **`AudioPlaybackStats`** interface of the [Web Audio API](/docs/Web/API/Web_Audio_API) provides access to duration, underrun, and latency statistics for the associated AudioContext. These statistics allow you to measure audio delay and glitches. An audio context's `AudioPlaybackStats` object can be accessed via its AudioContext.playbackStats property. The returned `AudioPlaybackStats` object is li
AudioPlaybackStats: underrunEvents property
Web Audio API The **`underrunEvents`** read-only property of the AudioPlaybackStats interface is a number indicating how many [underrun events](/docs/Web/API/AudioPlaybackStats#underrun_event) have occurred since the audio context was initialized. ## Value An integer indicating the number of underrun events. Initialized to `0`. ## Examples ### Basic usage ```js const audioCtx = new AudioContext(); const stats =
AudioPlaybackStats: toJSON() method
Web Audio API The **`toJSON()`** method of the AudioPlaybackStats interface returns a JSON-serializable plain object representing the `AudioPlaybackStats` object. The method is automatically called by JSON.stringify() when an `AudioPlaybackStats` object is encountered during [JSON](/docs/Glossary/JSON) serialization. ## Syntax ```js-nolint toJSON() ``` ### Parameters None. ### Return value A JSON-serializable
AudioPlaybackStats: underrunDuration property
Web Audio API The **`underrunDuration`** read-only property of the AudioPlaybackStats interface is a number indicating the total duration of the [underrun events](/docs/Web/API/AudioPlaybackStats#underrun_event) that have occurred since the audio context was initialized. ## Value A double-precision floating point number indicating the duration of underrun events, in seconds. Initialized to `0`. ## Examples ### B
AudioPlaybackStats: averageLatency property
Web Audio API The **`averageLatency`** read-only property of the AudioPlaybackStats interface is a number indicating the average latency since the audio context was initialized or since AudioPlaybackStats.resetLatency() was last called. ## Value A double-precision floating point number indicating the average latency, in seconds. ## Examples ### Basic usage ```js const audioCtx = new AudioContext(); const stats
AudioPlaybackStats: resetLatency() method
Web Audio API The **`resetLatency()`** method of the AudioPlaybackStats interface resets the start of the interval during which latency statistics are measured to the BaseAudioContext.currentTime. ## Syntax ```js-nolint resetLatency() ``` ### Parameters None. ### Return value None (undefined). ## Examples ### Basic usage ```js const audioCtx = new AudioContext(); const stats = audioCtx.playbackStats; // ..