How to add rectangle in desired region

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
manmanda
Posts: 17
Joined: 2014-04-16T13:34:38-07:00
Authentication code: 6789

How to add rectangle in desired region

Post by manmanda »

diffbc.bmp image is created after executing below command
composite bc1.bmp bc2.bmp -compose difference diffbc.bmp. My question is how to add rectangle around the desired region for giving hint which one to look at after diffbc.bmp is created instead looking at whole image as shown by red color in below image path

http://i57.tinypic.com/ig009z.jpg

I have gone through some basic commands of draw but didn't get any clue.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: How to add rectangle in desired region

Post by fmw42 »

It is not clear what you are asking to do. Can you post your input images to dropbox.com (public folder) and put links here, so that we can test your command and see what is going on.

If you want to see where the differences are with red highlights, you could use

Code: Select all

compare -metric rmse bc1.bmp bc2.bmp diffbc.bmp
If you know where you want to draw a red rectangle, then

Code: Select all

convert diffbc.bmp -fill none -stroke red -draw "rectangle x1,y1 x2,y2" diffbc_draw.bmp
where x1,y1 is one corner of the rectangle and x2,y2 is the diagonally opposite corner of the rectangle.
manmanda
Posts: 17
Joined: 2014-04-16T13:34:38-07:00
Authentication code: 6789

Re: How to add rectangle in desired region

Post by manmanda »

thanks for your reply
Post Reply