There's already a JPEG-XL decoder written in Rust: https://crates.io/crates/jxl-oxide
It would be nice to hear why it's not good enough.
There's already a JPEG-XL decoder written in Rust: https://crates.io/crates/jxl-oxide
It would be nice to hear why it's not good enough.
(In the case of AV1 I think they eventually gave up and started offering dav1d on Android, but not before shipping their in-house implementation that was much less efficient and no safer than state of the art, perplexing everyone in the process.)
[1] The main blocker for J40 was that I don't really want to keep it less safe than I hope to achieve, but I also want to keep it in C for practical reasons. This and my daily job prevented any significant improvements so far.
As good as Oxide might be it looks like a one developer project.
As for why jxl-oxide can't be used yet — it just isn't mature enough yet. They're still finding unimplemented or incompatible features, and have some unoptimized code.
JPEG XL is big and complex – it is designed to have every feature of every competing codec (from vector graphics to video), and beat them all on compression in every case, so it's a half a dozen of different codecs in a trench coat.
libjxl decoder is 3-5x smaller in binary and 10x smaller in specification text size than an avif decoder