Image.magick failed when convert jpg to png

Magick++ is an object-oriented C++ interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick++.
Post Reply
jyz19880823
Posts: 2
Joined: 2019-11-28T01:07:09-07:00
Authentication code: 1152

Image.magick failed when convert jpg to png

Post by jyz19880823 » 2019-11-28T01:16:44-07:00

1. Image image;
2. image.read(srcBlob);
3. image.magick("PNG");
4. image.write(&blob);
I use ImageMagick++ (6.7.8.9) with node, it works without line 3.
If add line 3 to convert JPG to PNG, it will crash.

node: symbol lookup error: /root/gif-magick/build/Debug/im.node: undefined symbol: _ZN6Magick5Image5writeEPNS_4BlobERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

PS: the codes works fine on mac os 10.15, but crash on centos.

snibgo
Posts: 12400
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Image.magick failed when convert jpg to png

Post by snibgo » 2019-11-28T01:52:20-07:00

IM v6.7.8.9 is very very very old. I suggest you upgrade.

I don't know what "node" is.

That symbol looks weird. Is that a run-time error, or compile or link?
snibgo's IM pages: im.snibgo.com

jyz19880823
Posts: 2
Joined: 2019-11-28T01:07:09-07:00
Authentication code: 1152

Re: Image.magick failed when convert jpg to png

Post by jyz19880823 » 2019-11-29T00:44:31-07:00

snibgo wrote:
2019-11-28T01:52:20-07:00
IM v6.7.8.9 is very very very old. I suggest you upgrade.

I don't know what "node" is.

That symbol looks weird. Is that a run-time error, or compile or link?
the version is the only one on the server environment.
Node is the nodejs, which can work with c++ by addons.
it is run-time error. if add some condition to pass by image.magick('png'), it works all right.
I will try to upgrade the package~
thanks.

Post Reply