Skip to content

Instantly share code, notes, and snippets.

@akrnmd
Last active October 3, 2020 00:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save akrnmd/be86c200e4f23ebe684c829f02d3181c to your computer and use it in GitHub Desktop.
Save akrnmd/be86c200e4f23ebe684c829f02d3181c to your computer and use it in GitHub Desktop.
Capture and compare two images. #SenseTalk #eggplant
set CaptureArea to (0, 0, 100, 100) -- Set Capture Area.
CaptureScreen "C:\Users\[UserName]\Image-Before.png", CaptureArea
//Your Actions
CaptureScreen "C:\Users\[UserName]\Image-After.png", CaptureArea
if file "C:\Users\[UserName]\Image-Before.png" as data is equal to file "C:\Users\[UserName]\Image-After.png" as data then
log "Image-Before and Image-After are same images."
else
log "Image-Before and Image-After are different images."
end if
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment