Hi,
I have to convert multiple files in a single command (convert.exe)
e.g.
I have two jpeg file
1.jpeg
2.jpeg
I have to convert 1.jpeg to 1_new.jpeg with options
and 2.jpeg into 2_new.jpeg with format options.
How I can use convert command to perform above operation.
Is it possible with "convert" command to perform this operation?
I have tried like
convert 1.jpeg -resize 100X200 1_new.jpeg 2.jpeg -resize 200X300 2_new.jpeg.
But this does not work.
Please help me out..
Thanks.
converting multiple files in single command
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: converting multiple files in single command
You have to use parenthesis to process each image and -write to write it out.
convert \( image1 ... -write image1_new +delete \) \( image2 ... -write image2_new +delete \) null:
see parenthesis processing, delete and write at:
http://www.imagemagick.org/Usage/basics/#image_seq
http://www.imagemagick.org/Usage/files/#write_seq
Note: on windows \( becomes just (
see
http://www.imagemagick.org/Usage/windows/
convert \( image1 ... -write image1_new +delete \) \( image2 ... -write image2_new +delete \) null:
see parenthesis processing, delete and write at:
http://www.imagemagick.org/Usage/basics/#image_seq
http://www.imagemagick.org/Usage/files/#write_seq
Note: on windows \( becomes just (
see
http://www.imagemagick.org/Usage/windows/