qt-heif-image-plugin: Qt plugin for HEIF images
This is a Qt image plugin for HEIF images, wrapping libheif. It enables
existing Qt applications to open and save
.heic files, such as those from
Currently, support is limited to the following:
- Basic reading and writing of the primary image
- Reading of files with multiple top-level images
Note: This plugin is currently in progress for inclusion in qtimageformats. Please see the Qt Gerrit page or bug report for updates. Contributions should be made there, if possible. I will try to keep this repository up to date.
A PPA exists for Ubuntu users. For xenial and earlier, the libheif repository must also be enabled for dependencies.
$ sudo add-apt-repository ppa:jakar/qt-heif $ sudo apt update $ sudo apt install qt-heif-image-plugin
Packages built against buster and unstable are provided on the latest release page.
Package is available in the RPM Fusion free repository. To install it you need to enable RPM Fusion repo first - see Enable RPM Fusion on your system. Then it can be installed with following command:
$ sudo dnf install qt-heif-image-plugin
Users of other systems should build from source.
Building from source
- Qt 5 (Core and GUI modules)
- libheif (≥ version 1.1)
Get the source code:
$ git clone https://github.com/jakar/qt-heif-image-plugin.git $ cd qt-heif-image-plugin
Configure with cmake and compile:
$ mkdir build $ cd build $ cmake .. $ make
$ sudo make install
The built library will be installed to
CMAKE_INSTALL_PREFIX will not be honored. Qt only searches in select
directories for plugins.
Alternatively, to use with a specific application, place the plugin in
$APPDIR is the directory containing the
Any application that (directly or indirectly) uses
QImageReader to open image
files should automatically be able to use this plugin.
This has been successfully used with the following:
To test the plugin, Dumageview was created.