Tiff split

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
spieler
Posts: 47
Joined: 2004-10-08T09:03:16-07:00
Location: Iowa

Tiff split

Post by spieler »

I have a 74 page tiff file that I want to split into individual pages. It's currently at 256 colors with LZW compression.

From my understanding, if I do
convert a.tif b%03d.tif
it will load all pages as uncompressed tiffs into memory and once that is done it will output one page at a time. That's a lot of memory

So, instead I try
convert "a.tif" b%03d.tif
varying i from 0 to 73.
This works great for the first few images but gets slower as i increases, so it may not actually be releasing memory completely. This is in windows and convert.exe can be up to 768 MB for it's peak memory, but under 1 MB for it's current usage in the middle of this. At the same time, the memory usage on my computer is maxed out. By the time I get to the last image, it takes several minutes (perhaps due to all the disk i/o writing the cache) to extract the page.

Is this how ImageMagick is intended to work?

On a side note, I just used tiffsplit from libtiff and it was done in no time. Am I better off using this specialized program instead of ImageMagick?
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Post by magick »

The tiffsplit program would be a better solution for your particular problem.
Post Reply