From owner-freebsd-questions@FreeBSD.ORG Tue Sep 2 15:02:45 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B8600106567C for ; Tue, 2 Sep 2008 15:02:45 +0000 (UTC) (envelope-from freebsd@optiksecurite.com) Received: from tomts24-srv.bellnexxia.net (tomts24-srv.bellnexxia.net [209.226.175.187]) by mx1.freebsd.org (Postfix) with ESMTP id 54AB08FC18 for ; Tue, 2 Sep 2008 15:02:45 +0000 (UTC) (envelope-from freebsd@optiksecurite.com) Received: from toip39-bus.srvr.bell.ca ([67.69.240.40]) by tomts24-srv.bellnexxia.net (InterMail vM.5.01.06.13 201-253-122-130-113-20050324) with ESMTP id <20080902150242.SPRZ1580.tomts24-srv.bellnexxia.net@toip39-bus.srvr.bell.ca> for ; Tue, 2 Sep 2008 11:02:42 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApoEAPXrvEhKD7BS/2dsb2JhbACzdYFp Received: from mtrlpq02-1242542162.sdsl.bell.ca (HELO [69.69.69.183]) ([74.15.176.82]) by toip39-bus.srvr.bell.ca with ESMTP; 02 Sep 2008 11:02:36 -0400 Message-ID: <48BD5574.7010107@optiksecurite.com> Date: Tue, 02 Sep 2008 11:02:12 -0400 From: FreeBSD User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: How to compare 2 images from command line X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Sep 2008 15:02:45 -0000 Hi everyone, I'm trying to determine if 2 jpeg images are identical. The images are screenshots taken with scrot at different times. The point is to know if the display is working correctly. I tried to use 'diff' but without success, probably because of the metadata included in the image. I also tried the 'compare' command from imagemagick, but it produce an image containing the difference between the 2 images instead of telling me if both images are identical. So, my question is what are you using to determine if 2 images are identical? I'm using FreeBSD 7.0 and I need to be able to script this comparaison for an integration in Nagios. Thank you, Martin