Closed sasmaster closed 1 year ago
I think this is a likely a question for the texSubImage2D bindings in WASM and not WebCodecs. I suspect it's not operating on a VideoFrame object but raw bytes, so would need some sort of understanding of a YUV format to support this. Again that's a bit outside of WebCodecs, so I'm going to close this.
Hi. I am implementing a kind of hybrid decoding solution using C++ (Emscripten) and JS. Demuxer is running on the C++ side as well as WebGL surface updates,but decoding is done on Js side using webcodecs VideoDecoder. Cool feature I have noticed is that in Js app gl.texSubImage2D takes care of converting YUV NV12 into RGB(A), but it doesn't happen when calling this methods in Emscripten. Is it something that can be once day moved to the "lower level" APis in the browser so that wasm developers won't have to implement color space conversions? Thanks.