Problem convert tif to jpg

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
Fab2k

Problem convert tif to jpg

Post by Fab2k »

Hello everybody,

I'm new at this board and just made my first steps with ImageMagick. I'm working on a windows xp system and downloaded the ImageMagick 6.5.5-8-Q16 version.

I have some troubles with converting tif to jpg files. First of all ImageMagick works pretty slow and my files aren't that big. The maximum file size is around 600kb with width maximum 19000px and height 14000px.

Is it normal that ImageMagick has troubles with this size of images?

I need to use ImageMagick with the phmagick plugin for a web project so the convertion process can't take that long.

I would really appreciate some help with this problem cause I'm kind of desprate. I tried to search the forum for help but I guess I make a rookie mistake and the forum problems are mostly pretty specific.

Cheers in advance!

Fabian
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Problem convert tif to jpg

Post by magick »

The maximum file size is around 600kb with width maximum 19000px and height 14000px.
See http://www.imagemagick.org/script/architecture.php. Because of the size of your image it is most likely being cached to disk which is 1000 times slower than memory. On our system, with 32GB of memory, the conversion takes just a few seconds. If all you need is to convert from TIFF to JPEG without resizing, you probably want a custom program that simply grabs one TIFF scanline at a time and writes the scanline to JPEG.
Fab2k

Re: Problem convert tif to jpg

Post by Fab2k »

Thanks for the fast response.

I didn't read the architecture page so the problem finally makes sense. I do need to resize the image. Are there any options to bypass this problem?
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Problem convert tif to jpg

Post by magick »

You have three options: 1) get a faster machine with more memory; or 2) use some other program; or 3) adjust your expectations about how fast a computer can manipulate more than a quarter million pixels.
Fab2k

Re: Problem convert tif to jpg

Post by Fab2k »

Just discovered that my response was a bit stupid.

Thanks anyways!
webereinc

Re: Problem convert tif to jpg

Post by webereinc »

As a follow-up on this thread... I, too, need to convert some large black-and-white TIFs into GIFs or JPGs for viewing on the web. Specifically, a mention in one of the previous posts said: "If all you need is to convert from TIFF to JPEG without resizing, you probably want a custom program that simply grabs one TIFF scanline at a time and writes the scanline to JPEG." Is anyone aware of a program such as this? Wouldn't it be quicker to convert this way?

Also, is there a parameter that can be passed to convert to have it use a lower pixel depth while converting? On my linux (Ubuntu) machine, Q16 is creating a huge pixel cache while trying to convert a 14400x9600 black-and-white TIF into a GIF. Otherwise, I will need to find a way to re-compile a Q8 version of ImageMagick into my Linux machine.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Problem convert tif to jpg

Post by fmw42 »

Post Reply