Dynamic File list input to concatenate

ImageMagickObject is a Windows COM+ interface to ImageMagick. COM+, Visual Basic, and Delphi users should post to this discussion group.
Post Reply
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

Dynamic File list input to concatenate

Post by foruforewer »

Hi Friends,

I have hundreds of sets of images (folders that contains images) and each have some image files but not at fixed count. I want to concatenate and make a rill per set in which I am not able to get how to make input file counts as dynamic.

Command would look like below

Code: Select all

montage FOLDER1\IMAGE_1.JPG FOLDER1\IMAGE_2.JPG FOLDER1\IMAGE_3.JPG..... -mode concatenate -tile 1x output.jpg
I can get list of each folder with dir /B>list.txt but than on next i dont know how to pass this list to image magick
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Dynamic File list input to concatenate

Post by fmw42 »

You should be able to one of the following:

1) put your list into a variable and call the variable inside the montage command in place of the images

montage yourvariable ....

2) put your list into a text file and read the text file into montage in one of the following ways (depending upon whether montage accepts the file symbol @)

montage @filelist.txt ....

or

convert @filelist.txt miff:- | montage - .......

or

convert @filellist.txt image.miff
montate image.miff ....


For windows variables, see http://www.imagemagick.org/Usage/windows/
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

Re: Dynamic File list input to concatenate

Post by foruforewer »

Thanks, @list.txt worked for me
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

Re: Dynamic File list input to concatenate

Post by foruforewer »

one error noticed as below

Can i handle image with more than 65500 pixels???

montage @list.txt -mode Concatenate -tile 1x D:\47530313_TILE.jpg
Magick: Maximum supported image dimension is 65500 pixels `D:\47530313_TILE.jpg' @ error/jpeg.c/EmitMessage/235.
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Dynamic File list input to concatenate

Post by magick »

Can i handle image with more than 65500 pixels???
ImageMagick can handle tera-pixels, however, the JPEG image format is limited to 65535x65535 pixels. Try using another pixel format such as PNG which supports larger image sizes.
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

Re: Dynamic File list input to concatenate

Post by foruforewer »

Can you please guide me for below.
Put your list into a variable and call the variable inside the montage command in place of the images.
@List.txt has stopped working as it contains full network path as below and montage is not working if full network path is there.

Code: Select all

\\networkpath\folder\file_001.jpg
\\networkpath\folder\file_002.jpg
.
.
.
.
\\networkpath\folder\file_200.jpg
Post Reply