Open Grandsome opened 1 year ago
I did some searching but couldn't find a Java language binding for the libheif
library, which means MapTool won't be able to use it.
(Also, the README for the Git repo also says the API isn't stable yet. That's not a huge problem for MapTool since any Java lib would have to abide by the Image SPI anyway, but it means there's likely to be a lot of updates to the Java lib in the near-term for anyone who takes on supporting it.)
Might be possible to use https://github.com/lanthale/libheiffx and convert it with SwingFXUtils.
That library seems pretty risky to me (in terms of technical debt), and without much payback. Once the renderer is redone using JFX, then animation can be supported and AVIF makes a little more sense (given that animations can be significantly smaller than they are in WebP).
Is your feature request related to a problem? Please describe. Add support for the AVIF file format, it has a comparable compression ratio to WebP, but less destructive when it comes to image quality. Currently, using WebP with the program, it works well most of the time, but sometimes the loss of quality is very noticeable, this happens far less often with AVIF, especially since most portrait source are already compressed, and we're compressing the image at least twice. I'm a bit loss of information averse.
Describe the solution you'd like I'm not sure which encoder library you guys use, but the official AVIF one is here, but FFmpeg and SAIL also support it.
Describe alternatives you've considered Currently, using WebP, it works well most of the time, but sometimes the loss of quality is very noticeable. Could still use JPEG, but I'm not sure if TokenTool can just crop a file losslessly if the output format is the same as the input one.
Additional context Current browser support 83%.