Creating multipage Tiff from file list

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?".
sergiokapone
Posts: 17
Joined: 2012-10-22T04:58:55-07:00
Authentication code: 67789

Re: Creating multipage Tiff from file list

Post by sergiokapone »

fmw42 wrote: 2017-06-26T10:56:25-07:00 Those files should be deleted automatically. If they do not, then there is something wrong. You can delete them. See if they get left behind again.
Yes, the files deleted automatically after combining if the number of files is small. But if number of files over 400, I get system warning about free space, and thus, combining fail.
fmw42 wrote: 2017-06-26T10:56:25-07:00 But what was your exact command line? If you do not reference your files correctly, perhaps bogus files will be created and left in your TEMP folder. Be sure you command is correct.
My command line same as you recomended.

Code: Select all

magick *.tiff newimage.tiff
Also I get an warnings during process

Code: Select all

magick: Unknown field with tag 292 (0x124) encountered. `TIFFReadDirectory' @ warning/tiff.c/TIFFWarnings/925.
Last edited by sergiokapone on 2017-06-26T11:40:17-07:00, edited 1 time in total.
Windows 10.0.14393, ImageMagick 7.0.6 0 portable Q16 x86
sergiokapone
Posts: 17
Joined: 2012-10-22T04:58:55-07:00
Authentication code: 67789

Re: Creating multipage Tiff from file list

Post by sergiokapone »

I also have tryed nconvert from here

It combine much faster and without using additional disk space

Code: Select all

nconvert -o newfile.tiff -multi -out tiff -c 7  *.tiff
Windows 10.0.14393, ImageMagick 7.0.6 0 portable Q16 x86
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Creating multipage Tiff from file list

Post by fmw42 »

ImageMagick will read all the files into memory as those temp files. So if you do not have enough temp space, that could be an issue. But ImageMagick will use disk if not enough RAM. But that would account for your large use of temp space if you have many images to make into a tiff. Whether you use *.tiff or @filename.txt, this will happen with ImageMagick.

You can remove the warning, which is from an unknown tiff tag by adding -quiet right after convert.
sergiokapone
Posts: 17
Joined: 2012-10-22T04:58:55-07:00
Authentication code: 67789

Re: Creating multipage Tiff from file list

Post by sergiokapone »

fmw42 wrote: 2017-06-26T11:50:45-07:00 ImageMagick will read all the files into memory as those temp files.
Ok, but why those temp files so huge and numerous? My input files much smaller. It is strange that IM create one temp file with 60 Mb per one input file 10 Kb.
Windows 10.0.14393, ImageMagick 7.0.6 0 portable Q16 x86
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Creating multipage Tiff from file list

Post by fmw42 »

I am not sure, but they probably get enlarged when converting to ImageMagick internal format. Also your tiff files may be compressed and during the conversion, ImageMagick must decompress them.
sergiokapone
Posts: 17
Joined: 2012-10-22T04:58:55-07:00
Authentication code: 67789

Re: Creating multipage Tiff from file list

Post by sergiokapone »

fmw42 wrote: 2017-06-26T11:59:51-07:00 I am not sure, but they probably get enlarged when converting to ImageMagick internal format. Also your tiff files may be compressed and during the conversion, ImageMagick must decompress them.
My tiffs compressed with CCITTFAX4. Can I avoid decompressing stage?
Windows 10.0.14393, ImageMagick 7.0.6 0 portable Q16 x86
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Creating multipage Tiff from file list

Post by fmw42 »

Can I avoid decompressing stage?
No, not that I know. ImageMagick will decompress and then recompress the output if desired by the -compress option.
sergiokapone
Posts: 17
Joined: 2012-10-22T04:58:55-07:00
Authentication code: 67789

Re: Creating multipage Tiff from file list

Post by sergiokapone »

fmw42 wrote: 2017-06-26T12:08:48-07:00
Can I avoid decompressing stage?
ImageMagick will decompress ...
It's a pity.

Thank you for help.
Windows 10.0.14393, ImageMagick 7.0.6 0 portable Q16 x86
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Creating multipage Tiff from file list

Post by snibgo »

Yes, IM de-compresses each input, and re-compresses the output.

IM is a general-purpose raster processing system. For some tasks, such as appending multiple tiffs into a single tiff, more specialist programs do the job faster and with less memory. For example, "tiffcp", available for Unix and Windows (via the Cygwin toolset).
snibgo's IM pages: im.snibgo.com
Post Reply