Okular doesn't allow your to open avif images. Please add support. AVIF Support in Web Browsers: https://caniuse.com/avif AVIF Has Arrived: https://jakearchibald.com/2020/avif-has-landed/
This is not on Okular, whose mage backend just use the Qt function to open files. The support for additional formats can be provided by plugins, and some more formats are supported by the kimageformats library, which is part of KDE Frameworks: https://invent.kde.org/frameworks/kimageformats/ In fact support for AVIF was added a few months ago, it should be available in the latest Frameworks releases: https://invent.kde.org/frameworks/kimageformats/-/merge_requests/8 https://kde.org/announcements/frameworks/5/5.78.0/ I'm thus closing this bug; please reopen it if it doesn't work with Frameworks >= 5.78.0.
*** This bug has been marked as a duplicate of bug 416941 ***
Actually, we may need to tell the kimgio backend that it can open that format. Sigh.
Yes, just to add image/avif to few files in https://invent.kde.org/graphics/okular/-/tree/master/generators/kimgio and it will work.
(In reply to dnovomesky from comment #4) > Yes, just to add image/avif to few files in > https://invent.kde.org/graphics/okular/-/tree/master/generators/kimgio > > and it will work. It should be done in a way that doesn't break horribly if kimageformats is not available or not fresh enough.
In Okular, using the open-file dialog, if you navigate to a folder that contains avif or webp images, the file selection dialog will not even list those file-types without the additional step of changing the filter from "All supported files" to "All files". Screenshot: https://i.imgur.com/wwVUuEU.png
(In reply to Lonnie from comment #6) > In Okular, using the open-file dialog, if you navigate to a folder that > contains avif or webp images, the file selection dialog will not even list > those file-types without the additional step of changing the filter from > "All supported files" to "All files". > > Screenshot: > https://i.imgur.com/wwVUuEU.png This is the easiest part of the problem that can be fixed by tweaking MimeType in the kimgio ".desktop" files. You can even add the type ("image/webp") in your system without recompiling Okular.
(In reply to Luigi Toscano from comment #5) > (In reply to dnovomesky from comment #4) > > Yes, just to add image/avif to few files in > > https://invent.kde.org/graphics/okular/-/tree/master/generators/kimgio > > > > and it will work. > > It should be done in a way that doesn't break horribly if kimageformats is > not available or not fresh enough. I made an experiment. I edited those files. Then I removed kimg_avif.so AVIF is still listed as supported but opening an AVIF file will fail with message "Unsupported image format" That's not a horrible breakage I think.
Will do. Likewise, I hope development makes these additional steps unnecessary for others. Thank you.
So are you going to submit a merge request? That would be nice. :)
A possibly relevant merge request was started @ https://invent.kde.org/graphics/okular/-/merge_requests/386
Git commit c38af3e695be5e0cd59732effdc5bb7d63a67951 by Albert Astals Cid. Committed on 24/03/2021 at 22:42. Pushed by aacid into branch 'release/21.04'. Add a few more formats supported by qimageformat plugins Related: bug 434889 M +6 -1 generators/kimgio/libokularGenerator_kimgio.json M +1 -1 generators/kimgio/okularApplication_kimgio.desktop M +1 -1 generators/kimgio/okularKimgio.desktop M +1 -1 generators/kimgio/org.kde.mobile.okular_kimgio.desktop https://invent.kde.org/graphics/okular/commit/c38af3e695be5e0cd59732effdc5bb7d63a67951