I am running the dos batch file below in Windows 7. It combines all 4 .jpg image files in the folder into one image file. It combines the images side by side. It works fine with 264 KB file size and maybe a bit larger but with with larger files it runs and the file it produces is zero bytes. I need to combine/tile images that are 1 MB. I don't know if the batch file is timing out because of a limitation with Windows or if there is a limitation with ImageMagick. If anyone has any ideas, I really appreciate the help. Thanks, Rick
SETLOCAL EnableDelayedExpansion
SET MONTAGE="C:\Program Files\ImageMagick\Montage"
...
%MONTAGE% *.jpg -geometry +0+0 -tile 4x1 combined.jpg
windows 7 batch file montage tile - problem with large files
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: windows 7 batch file montage tile - problem with large f
What is the version number of IM?
Do you get any errror message?
How many pixels are in your images? Montage probably needs 8 bytes for each input pixel, plus 8 bytes for each output pixel.
A jpeg of 1 MB could be 10 million pixels. 4 files would have 40 million pixels. That would be 320 MB for the input files, plus another 320 MB for the output file.
This might be a problem if your computer is small, with 1 or 2 GB of memory. But it should be just a performance problem, and shouldn't cause failure.
Is this a standard binary installation, or is it customised in some way?
Do you get any errror message?
How many pixels are in your images? Montage probably needs 8 bytes for each input pixel, plus 8 bytes for each output pixel.
A jpeg of 1 MB could be 10 million pixels. 4 files would have 40 million pixels. That would be 320 MB for the input files, plus another 320 MB for the output file.
This might be a problem if your computer is small, with 1 or 2 GB of memory. But it should be just a performance problem, and shouldn't cause failure.
Is this a standard binary installation, or is it customised in some way?
snibgo's IM pages: im.snibgo.com
Re: windows 7 batch file montage tile - problem with large f
The version of Image Magick is: ImageMagick-6.8.9-7, standard binary installation. My OS is Windows 7, 64-bit, with 3 GB RAM Memory, standard installation. I did not get any error message.
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: windows 7 batch file montage tile - problem with large f
You didn't say how many pixels were in each file.
Try "dir *.jpg". How many files do you have? Are there actually four?
You write the output jpeg to the same directory as the input jpegs, so repeating the command will try to add this file to the montage. This is generally not a good idea.
Try "dir *.jpg". How many files do you have? Are there actually four?
You write the output jpeg to the same directory as the input jpegs, so repeating the command will try to add this file to the montage. This is generally not a good idea.
snibgo's IM pages: im.snibgo.com
Re: windows 7 batch file montage tile - problem with large f
The number of pixels in each file is 35840 x 256, wide but not very tall. Is that the info you are looking for? If not, let me know and I will find out the number of pixels.
There are exactly four files. Writing to the output directory works fine with small size image files, but I will redirect the output to a separate directory just to be safe.
There are exactly four files. Writing to the output directory works fine with small size image files, but I will redirect the output to a separate directory just to be safe.
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: windows 7 batch file montage tile - problem with large f
Yes, that's what I meant. About 10 M pixels each.
With those dimensions and your command, I get an error message:
It seems that JPEG files can't be created that large. Choose another output format such as PNG.
(I'm on IM v6.8.9-5 on Windows 8.1.)
With those dimensions and your command, I get an error message:
Code: Select all
montage.exe: Maximum supported image dimension is 65500 pixels `c-0.jpg' @ error/jpeg.c/JPEGErrorHandler/322.
(I'm on IM v6.8.9-5 on Windows 8.1.)
snibgo's IM pages: im.snibgo.com