Open dreampiggy opened 5 years ago
The AVIF's official spec v1.0.0 is released. Maybe it's possible to support it in the middle of this year. See: https://aomediacodec.github.io/av1-avif/
Depends: https://github.com/strukturag/libheif/tree/avif to be merged in upstream.
Or depends the future of https://github.com/strukturag/libheif/issues/96 to use dav1d instead of libaom codec.
Currentlly I can build a preview of the AVIF support in the avif
branch.
libavif tagged a new release, 0.1.3. See Colorist for an example implementation.
@EwoutH Actually...I've created one SDWebImageAVIFCoder specify for AVIF coder. And it exactly use libavif v1.0.3 (from v0.2.0, see: release)...Please have a try :)
But to say, the libavif encoding speed is still a problem. From my local benchmark, it's 100x slower than WebP format, 100x slower than BPG image format... 😅
Benchmark code: ModernImageFormatBenchmark
And. This repo have a avif branch. It based on the libheif support for AVIF (see their readme, they also have a avif
branch).
The libheif codec implementation is far more performent than the AVIF, but it's not so stable. So this is why we currently only use that libavif for users. In the future, we will switch back to libheif codec implementation.
AVIF is a AV1 codec based HEIF container. The spec is here: https://aomediacodec.github.io/av1-avif/
Current third-party HEIF decoder libheif does not support this format natively. But however, it's a future format which based on AV1 (VP9 's next successor). And it's the competition of current HEVC/H.265
In short term, since that AVIF spec is still in draft, we decide not to do some work for that. But however, after that spec is release or the third-party HEIF decoder libheif have support for AVIF, I'll update this and introduce the support.