Batch processing flop and append

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
t1op
Posts: 2
Joined: 2012-06-23T17:40:26-07:00
Authentication code: 13

Batch processing flop and append

Post by t1op »

Is there a way to run this command
convert image.jpg ( -clone 0 -flop ) +append result.jpg
on all images in a directory?

Is there a way to use wildcards? Or is a script required?
I use Windows 7. I have never written a script before and from searching, I think it could take me days to try to figure out how to write one myself.

PS This command will create a mirror duplicate of an image and add it to the original image.
Thanks
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Batch processing flop and append

Post by fmw42 »

t1op wrote:Is there a way to run this command
convert image.jpg ( -clone 0 -flop ) +append result.jpg
on all images in a directory?

Is there a way to use wildcards? Or is a script required?
I use Windows 7. I have never written a script before and from searching, I think it could take me days to try to figure out how to write one myself.

PS This command will create a mirror duplicate of an image and add it to the original image.
Thanks

It is my understanding that a script loop would be required in either unix or dos to do that, since mogrify will not work with parenthesis processing as far as I know..

See

http://www.imagemagick.org/Usage/basics/#mogrify_not
http://www.imagemagick.org/Usage/windows/
t1op
Posts: 2
Joined: 2012-06-23T17:40:26-07:00
Authentication code: 13

Re: Batch processing flop and append

Post by t1op »

Thanks for the direction. I found this does the trick:

FOR %a in (*.jpg) DO convert %a ( -clone 0 -flop ) +append mirrored_%a

Simple :)
Post Reply