Closed TTiamo closed 3 years ago
It is possible (perhaps even likely) that the encoded data (e.g. the AV1 bitstream) may describe enough of the stream properties such that you could derive a VideoDecoderConfig that could be used to configure the VideoDecoder. Is this what you're aiming to do?
How much can be derived and exactly how to do so would be specific to the codec. Can you say what codec you're trying to use?
This is not generally how we expect folks to fill out the config though. Ideally, the config info would be somehow stored outside of the bitstream (e.g. in the track metadata of a webm file).
Please re-open if you have followup questions.
I'm not sure what's being asked. Are you trying to construct the decoder or configure it?
Here's a demo that does both: https://tguilbert-google.github.io/webcodecs/mp4/index.html
Relevant code snippets: