Page 1 of 1

Error using 'convert' command on tiff files

Posted: 2012-03-14T09:30:41-07:00
by uxlvr
I get the following error while trying to use the 'convert' command:

$ convert source.tif -pointsize 36 -draw "text 50,50 'BANNER GOES HERE' " output.tif
Assertion failed: (toff_t)tif->tif_size==n, file tif_open.c, line 449
Abort(coredump)

The same command works fine with JPG or PNG formats. Greatly appreciate any help to resolve this issue. Please note that I have got ImageMagick-6.7.4.0 installed on HP-UX 11.31 ia64 from the binaries downloaded from http://hpux.connect.org.uk/hppd/hpux/X1 ... k-6.7.4.0/

Thanks

Re: Error using 'convert' command on tiff files

Posted: 2012-03-14T10:17:25-07:00
by magick
Notice the exception occurs inside the TIFF delegate library, not ImageMagick. Its possible there is a structure offset due to a different version of libTIFF being utilized verses the one that ImageMagick was built with.

Post a URL to your source.tif image. We'll see if we can reproduce the problem.

Re: Error using 'convert' command on tiff files

Posted: 2012-03-14T11:28:13-07:00
by uxlvr
I can't provide a link to the source.tif file as I am inside a firewall.

I tried to upload to http://imgur.com/E3yK3 but it converted 'tif' to 'png'.

Is there any other way I can send you the file?

Thanks,
uxlvr

Re: Error using 'convert' command on tiff files

Posted: 2012-03-14T12:27:31-07:00
by uxlvr
Here is the link to the source.tif file https://docs.google.com/open?id=0B_8fAT ... czBzbkRqZw

Re: Error using 'convert' command on tiff files

Posted: 2012-03-14T13:30:32-07:00
by fmw42
uxlvr wrote:Here is the link to the source.tif file https://docs.google.com/open?id=0B_8fAT ... czBzbkRqZw

It downloads as png for me and not tiff. You could try using dropbox.

Re: Error using 'convert' command on tiff files

Posted: 2012-03-14T14:33:36-07:00
by magick
Fred, choose File->Download. It downloads as TIF.

The file converted without complaint for us. We're using ImageMagick 6.7.6-0 and libTIFF 3.9.5.

Re: Error using 'convert' command on tiff files

Posted: 2012-03-14T17:25:04-07:00
by fmw42
magick wrote:Fred, choose File->Download. It downloads as TIF.

The file converted without complaint for us. We're using ImageMagick 6.7.6-0 and libTIFF 3.9.5.

Thanks. Sorry I missed that. I thought I could just click on the image and select download. Each of these upload sites behaves differently and I missed looking under file as I had expected a more obvious download button or link.

Re: Error using 'convert' command on tiff files

Posted: 2012-03-15T06:55:59-07:00
by uxlvr
Not sure where I can go from here.

Since our server is HPUX 11.31 ia64, I asked our unix admin to install all the required binaries (depot files) from http://hpux.connect.org.uk/hppd/hpux/X1 ... k-6.7.4.0/ and obviously, it doesn't work for converting/modifying tif files.

As it was pointed out that the issue could be with the libtiff library, I downloaded and compiled v3.9.5 locally (no depot files exist for v3.9.5) but was not able to test it. Is there a way I can tell 'convert' to use the local path instead of the system path?

Any suggestion would be of great help.

Re: Error using 'convert' command on tiff files

Posted: 2012-03-15T08:53:14-07:00
by uxlvr
Hi magick, Would you please let me know if this worked in unix or windows platform? if it is unix, may I know what is OS you tested this?

Re: Error using 'convert' command on tiff files

Posted: 2012-03-15T10:09:58-07:00
by fmw42
This works successfully for me on IM 6.7.6.0 Q16 Mac OSX Snow Leopard

convert source.tif -pointsize 36 -draw "text 50,50 'BANNER GOES HERE' " source_tmp.tif

Perhaps your libtif delegate library needs to be updated (and/or IM)

Re: Error using 'convert' command on tiff files

Posted: 2012-03-15T13:33:09-07:00
by uxlvr
Fred, Thanks for the reply.

I have installed IM Version: ImageMagick 6.7.5-7 in my laptop (Windows 7) and the 'convert' command works fine without any issues.

For the unix server, first I requested the unix admin to download and install libtiff v4.0 (that was the only other depot file that was available for HPUX 11.31 ia64) but that didn't help. Then, I downloaded and built libtiff v3.9.5 locally, but can't figure out how to instruct 'convert' to look in my local path instead of '/usr/local/lib'. Unfortunately, I don't have root access and hence have to prove that the v3.9.5 libtiff libraries would actually work before requesting to install that in the system!!!

btw, I also noticed that when I try to open the 'source.tif' using 'display' command, it fails with the same error.

Re: Error using 'convert' command on tiff files

Posted: 2012-03-15T14:22:50-07:00
by fmw42
It displays fine for me.

display source.tif

Also just so you know, my libtiff is

TIFF* TIFF rw+ Tagged Image File Format (LIBTIFF, Version 3.9.5)

Perhaps your server version of IM is not properly installed. You could try to have them uninstall and reinstall. If so, also reinstall libtiff.

Can you convert your image locally to some other format, upload it to your server and test to see if it has a problem. Then you might know if it is IM or libtiff.