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

https://wpt.fyi/results/webcodecs/video-encoder-config.https.any.html is expecting VideoEncoder.isConfigSupported to throw

youennf opened this issue · comments

According the spec, VideoEncoder.isConfigSupported only throws in case https://w3c.github.io/webcodecs/#valid-videoencoderconfig returns false.
The test (and Chrome) is expecting to throw in more cases, like if width or height is very big.
Either we should update the spec accordingly or VideoEncoder.isConfigSupported should return supported = false in that case.

Agreed, throwing is for when the config is structurally invalid. Other reasons should produce a VideoEncoderSupport with supported === false.

OK, I'll update the WPT test.

@sandersdan, could you look at WPT web-platform-tests/wpt#40691 ?

Looks good to me, but note that I don't have the power to approve WPT changes.