Page 1 of 1

PNG support natively

Posted: 2008-02-18T15:25:13-07:00
by LangeNet
I see there is a delegate for PNG, but I seem to be able to read and convert PNG to TIFF without the library.
So I'm confused - ... I know, again... as to why there is an addition PNG component for IM.

Re: PNG support natively

Posted: 2008-02-19T06:15:53-07:00
by tsdineen
What platform are you on?

Re: PNG support natively

Posted: 2008-02-19T08:04:32-07:00
by LangeNet
Tru64 5.1b

Re: PNG support natively

Posted: 2008-02-19T08:10:32-07:00
by magick
See http://thewrittenword.com/. They provide pre-compiled binaries of Open Source software on AIX, HP-UX, IRIX, Redhat Linux, Solaris, and Tru64 UNIX. Note, we have no connection with these folks other than they provide ImageMagick with their distributions.

Re: PNG support natively

Posted: 2008-02-19T09:18:53-07:00
by LangeNet
My question stems from the fact that I can do:

convert 003_0576_0528.png 003_0576_0528.tiff


and yet I haven't installed any png libraries.

Re: PNG support natively

Posted: 2008-02-20T05:14:48-07:00
by tsdineen
There is probably a libpng in /usr/lib or some other $LD_LIBRARY_PATH location.

do an ldd or chatr on convert and see where it might be pulled in.

Re: PNG support natively

Posted: 2008-02-21T09:46:12-07:00
by LangeNet
No sign libpng..... :? Strange eh???

root_rcsr01# ldd /usr/local/bin/convert

Main => /usr/local/bin/convert
libMagickCore.so.1 => /usr/local/lib/libMagickCore.so.1
libMagickWand.so.1 => /usr/local/lib/libMagickWand.so.1
libtiff.so.3 => /usr/local/lib/libtiff.so.3
libc.so => /usr/shlib/libc.so
libXext.so => /usr/shlib/libXext.so
libXt.so => /usr/shlib/libXt.so
libpthread.so => /usr/shlib/libpthread.so
libSM.so => /usr/shlib/libSM.so
libICE.so => /usr/shlib/libICE.so
libX11.so => /usr/shlib/libX11.so
libm.so => /usr/shlib/libm.so
libmach.so => /usr/shlib/libmach.so
libexc.so => /usr/shlib/libexc.so
libgcc_s.so.1 => /usr/local/lib/libgcc_s.so.1

Re: PNG support natively

Posted: 2008-02-21T18:12:20-07:00
by anthony
Not strange.

To allow "convert" to run when not all the librarys and delegates are present, IM calls 'coder' modules that have the dependancy to the library needed. If the library is not present only that 'coder' module will fail, and NOT the whole "convert" command.

On my machine these coder modules are located in
/usr/lib/ImageMagick-6.3.8/modules-Q16/coders

Code: Select all

ldd /usr/lib/ImageMagick-*/modules-Q16/coders/tiff.so
...
libtiff.so.3 => /usr/lib/libtiff.so.3 (0x006e6000)
...

This means that if a user does not need 'tiff', or 'dpx' or 'pict' or some other image format, he does not need to install all the librarys because IM depends on it.

That is IM makes the dependancy optional, You only need the library if you want to use that image format. You don't need it if you never use it!

I wish more packages did this (like Fedora gnome!) as the dependency tree they generate can result in huge amounts of software being installed on your machine, which you never actually use!