Is there anything in PB that allows you to compare two images to see if
they are identical?


J. Baker wrote:If you use Point(), you can compare per pixel. You can even use Plot() to draw hot pink (or something like that) on the second image or even a third, to see the difference.

wilbert wrote:If you get the address of the pixel data, you could use CompareMemory.
It shouldn't be. Do all your comparing in the background. Not like where you can visually see it comparing in a window or something. Then when done comparing, then draw the result images so you can visually see it.spacebuddy wrote:J. Baker wrote:If you use Point(), you can compare per pixel. You can even use Plot() to draw hot pink (or something like that) on the second image or even a third, to see the difference.
I tried that, but it is to slow for me

Code: Select all
EnableExplicit
Define ImageHandle.i, *Buffer, Pitch.i, Length.i, Result.l
CreateImage(ImageHandle, 300, 200)
StartDrawing(ImageOutput(ImageHandle))
*Buffer = DrawingBuffer()
Pitch = DrawingBufferPitch()
Length = Pitch * ImageHeight(ImageHandle)
Result = CRC32Fingerprint(*Buffer, Length)
StopDrawing()
Debug Hex(Result, #PB_Long)