![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Apr 2005
Posts: 6
Rep Power: 0
![]() |
hi firends,
I m storing a image in table using AppendChunk. Now i want to check this image with another image from another table.So is there any way so that i can compare that 2 images to see whether that 2 images are identical or not? |
|
|
|
|
|
#2 |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
As long as you know how the image data is stored, you can always compare pixel by pixel to see if they're identical. Similar is another story. By hashing the data properly, you could establish with some degree of probability that two images with the same hash are identical. The probability is less than 1.0.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
#3 |
|
Troll
Join Date: Apr 2005
Location: Texas
Posts: 732
Rep Power: 4
![]() |
It depends. If the image could be a variety of formats, then you will need to be able to interpret the data rather than just compare it. An image is still identical pixel-wise between two formats, but bit-wise totally different. I would reccomend that in a production type scenario, but if you aren't doing this seriously then a byte by byte comparison would work. What's your definition of identical? Do you mean the same visually or the same as stored? If the same visually, exactly the same to the pixel or just look the same?
__________________
MD5(sig) = bcef75433db02e9ad9bf81d6f7c5c270 |
|
|
|
|
|
#4 | |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
Quote:
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|