Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

duplicate image

Status
Not open for further replies.

foxfito

Programmer
Sep 29, 2003
15
0
0
EC
Hi,
I´m trying to create a program that needs to identify duplicate images from a folder.
Does anyone know of any SDK or OCX or something... or any code available???
Please let me know.
Thank you!!!
 
Can you be more specific?

Do you mean, identify files with different names but which have identical contents - or are you after something that compares the contents of image files to see if they are similar?


Regards

Griff
Keep [Smile]ing
 
Yes, that´s what i mean, you know any demo of it?
 
Which one?

a) Identical file contents (easy)
b) Similar images (no idea)



Regards

Griff
Keep [Smile]ing
 
You may wish to check to see if there is a C or C++ forum. This may be a better fit for that.


I don't know how you would read an Image in VFP. I guess you could try a low level read like FREAD. Look for it in help. I'd be interested in knowing if it works. If so, please share with the group.



Jim Osieczonek
Delta Business Group, LLC
 
Jim,

I'm with you.

Comparing two files is easy.

Two images for similarity is harder - you could decrypt and compare palettes and so forth, but it is very much a subjective assessment.

Where would you start?

If you took a colour photo and made it monochrome, it's similar but not the same!

Not my bag.


Regards

Griff
Keep [Smile]ing
 
i've found a freeware that does the thing, i.e. scan images in a folder, compare them, if identical, delete or ask you what to do about them. it's called PixScan. maybe this freeware will save you time coding.

kilroy [trooper]
 
Well, The simplest way can be comparing the file contents like:

lcFile1 = filetostr(<file>)
lcFile2 = filetostr(<file>)

if lcFile1 == lcFile2
** same
else
** different
endif

Vikas
 
Vikas,

Interesting. I tried it on a small bmp file and then typed:

? lcFile

into the command window. It made a very big lcfile, and it scrolled for quite a while.

I suspect this approach will only work on smaller image files. but large files would take up too much memory.

Have you tried it on large files?

Jim Osieczonek
Delta Business Group, LLC
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top