AudioDecoder: dequeue event
WebCodecs APIwindowanddedicated
WebCodecs APIwindow_and_dedicated
The dequeue event of the AudioDecoder interface fires to signal a decrease in AudioDecoder.decodeQueueSize.
This eliminates the need for developers to use a setTimeout() poll to determine when the queue has decreased, and more work should be queued up.
Syntax
Use the event name in addEventListener():
addEventListener("dequeue", (event) => { })
Alternatively, assign to the event handler property of the interface:
ondequeue = (event) => { }
Example
audioDecoder.addEventListener("dequeue", (event) => {
// Queue up more decoding work
});