Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REQUEST] HEIC support in ImageMagick #4581

Closed
gerdemb opened this issue Apr 25, 2021 · 3 comments · Fixed by #4585
Closed

[REQUEST] HEIC support in ImageMagick #4581

gerdemb opened this issue Apr 25, 2021 · 3 comments · Fixed by #4585
Labels
enhancement request to enhance existing package update request to update existing package

Comments

@gerdemb
Copy link

gerdemb commented Apr 25, 2021

Would be nice if the ImageMagick supported HEIC files. Seems like libheif is already installed by Synology, so should just be a matter of getting ImageMagick to use it.

$ magick identify --version
Version: ImageMagick 7.0.7-30 Q16 aarch64 2018-05-06 https://www.imagemagick.org
Copyright: © 1999-2018 ImageMagick Studio LLC
License: https://www.imagemagick.org/script/license.php
Features: Cipher DPC HDRI
Delegates (built-in): freetype jng jpeg png tiff xml zlib
$ ls -l /lib/libheif*
lrwxrwxrwx 1 root root     16 Apr  9 12:36 /lib/libheif.so -> libheif.so.1.4.0
lrwxrwxrwx 1 root root     16 Apr  9 12:36 /lib/libheif.so.1 -> libheif.so.1.4.0
-rwxr-xr-x 1 root root 355256 Mar  1 20:29 /lib/libheif.so.1.4.0
@hgy59
Copy link
Contributor

hgy59 commented Apr 26, 2021

@gerdemb it is not as easy as linking to the already installed shared libraries.
But you can use imagemagick installed in the DSM system, as it was built with HEIC support:

$ which convert
/bin/convert

$ convert --version
Version: ImageMagick 6.9.10-27 Q8 x86_64 2021-03-02 https://imagemagick.org
Copyright: © 1999-2019 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC OpenMP
Delegates (built-in): bzlib fontconfig freetype heic jng jpeg lzma png tiff webp xml zlib

I was already working on a imagemagick package update about a year ago. I added heic, wmf and other file formats (but not yet svg as per #3881). Maybe I find some spare time to complete this,

$ which magick
/usr/local/bin/magick

$ ls -l $(which magick)
lrwxrwxrwx 1 root root 41 Apr 26 07:20 /usr/local/bin/magick -> /volume1/@appstore/imagemagick/bin/magick

$ magick --version
Version: ImageMagick 7.0.10-24 Q16 x86_64 2020-07-26 https://imagemagick.org
Copyright: © 1999-2020 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI Modules OpenMP(4.0)
Delegates (built-in): bzlib fontconfig freetype heic jng jp2 jpeg lcms ltdl lzma png tiff webp wmf xml zlib

The current synocommunity imagemagick package has only a few formats built in:

$ /var/packages/imagemagick/target/bin/magick --version
Version: ImageMagick 7.0.8-53 Q16 x86_64 2019-07-17 https://imagemagick.org
Copyright: © 1999-2019 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI
Delegates (built-in): freetype jng jpeg png tiff xml zlib

@hgy59 hgy59 added enhancement request to enhance existing package update request to update existing package labels Apr 26, 2021
@gerdemb
Copy link
Author

gerdemb commented Apr 26, 2021

Thanks for your comment. Actually, I was trying to use the synocommunity ImageMagick package as I was having trouble getting the built-in Synology version (/bin/convert) to convert HEIC files.

Eventually, I discovered that Synology has released a new package called "Advanced Media Extensions", that has a working version of ImageMagick here:

$ ls -al /volume1/@appstore/CodecPack/usr/bin
total 48
drwxr-xr-x 2 root root 4096 Jan 20 00:33 .
drwxr-xr-x 4 root root 4096 Jan 20 00:33 ..
-rwxr-xr-x 1 root root 6264 Jan 20 00:33 compare
-rwxr-xr-x 1 root root 6240 Jan 20 00:33 composite
-rwxr-xr-x 1 root root 6240 Jan 20 00:33 convert
-rwxr-xr-x 1 root root 6248 Jan 20 00:33 identify
-rwxr-xr-x 1 root root 6240 Jan 20 00:33 montage

It seems the version left in /usr/bin/convert is broken for HEIC images.

Leaving this comment in the hope that it might help anyone else having the same problem.

@hgy59
Copy link
Contributor

hgy59 commented Apr 28, 2021

@gerdemb you find pre-release packages here.

Please note that ARMv5 and old PPC Archs do not include the HEIC format (88f6281-6.1 and ppc853x-5.2)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement request to enhance existing package update request to update existing package
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants