w3c / webcodecs

WebCodecs is a flexible web API for encoding and decoding audio and video.

Home Page:https://w3c.github.io/webcodecs/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Is https://www.w3.org/TR/webcodecs/#dom-audioencoder-encode complete enough?

philn opened this issue · comments

WPT test https://github.com/web-platform-tests/wpt/blob/master/webcodecs/audio-encoder.https.any.js has channelNumberVariationTests and sampleRateVariationTests checking the input data matches the configuration of the encoder, but I see no mention of that in the spec.

Blink checks it, see https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/modules/webcodecs/audio_encoder.cc;l=509

cc @youennf @padenot @dalecurtis @sandersdan

I'd tend to agree, and follow Chromium's behaviour here. This is what Firefox implements as well.