Check pixel data for alterations

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
isonix
Posts: 1
Joined: 2015-06-08T04:50:04-07:00
Authentication code: 6789

Check pixel data for alterations

Post by isonix »

I wonder if there is a tool in ImageMagick that is able to identify potential areas of an image that may have been modified. If not, is there a technique I can look into?

I am mostly interested in finding obvious alterations, for example in a scanned transcript where someone copy and pasted some digits to change some grades.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Check pixel data for alterations

Post by snibgo »

You can easily find the pixels that have changed between two versions of an image.

But I suppose you have only one version. This is difficult. If you suspect copy-pasting of digits, you could compare appropriate crops from the image. If you find an exact match, you can be (almost) certain it has been copied.
snibgo's IM pages: im.snibgo.com
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Check pixel data for alterations

Post by magick »

If you have a reference image, you can use the compare utility. If the metric is not zero, its been altered and the exact location of the change can be visually checked in the output image:
  • compare -metric rmse transcript.png reference.png difference.png
Post Reply