w3c / webcodecs

WebCodecs is a flexible web API for encoding and decoding audio and video.
https://w3c.github.io/webcodecs/
Other
937 stars 131 forks source link

EncodedAudioChunkInit should probably also support AllowSharedBufferSource #788

Closed chrisguttandin closed 1 month ago

chrisguttandin commented 1 month ago

I've noticed that the data of a EncodedVideoChunkInit object is of type AllowSharedBufferSource while the data of a EncodedAudioChunkInit object can only be of type BufferSource.

https://w3c.github.io/webcodecs/#dictdef-encodedvideochunkinit https://w3c.github.io/webcodecs/#dictdef-encodedaudiochunkinit

It looks like EncodedVideoChunkInit was changed to align it with a WPT in #575 / #576. But a similar WPT with a SharedArrayBuffer also exists for EncodedAudioChunkInit and all browsers seem to pass it.

https://wpt.fyi/results/webcodecs/encoded-video-chunk.crossOriginIsolated.https.any.html?label=experimental&label=master&aligned https://wpt.fyi/results/webcodecs/encoded-audio-chunk.crossOriginIsolated.https.any.html?label=master&label=experimental&aligned

padenot commented 1 month ago

Fixed, closing.