ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Similarity factor?
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

PeterPanino

988 Posts

Posted - Sep 17 2013 :  05:50:35  Show Profile  Reply
Hi! Is it possible to calculate a similarity factor when comparing images? For example:

When comparing ImageA with ImageB, they have a similarity factor of 35%

When comparing ImageA with ImageC, they have a similarity factor of 22%

Of course, the similarity calculation should be based on various parameters, for example:

Distribution map of n predominant colors

Similarity between maps of shapes after transformation of image content to shape primitives

Etc. etc.

w2m

USA
1990 Posts

Posted - Sep 17 2013 :  08:08:56  Show Profile  Reply
The only similarity factor that I am aware of is:

TImageEnProc.CompareWith

Declaration
function CompareWith(SecondImage:TIEBitmap; DiffBitmap:TIEBitmap):double;

Description
Compares current image with SecondImage and returns a floating point value from 0 to 1 which specifies the percentage of equality. 1 means that two images are equal.
The algorithm compares only the intensity of the pixels, not the colors.

The DiffBitmap can be nil, otherwise it must be an 8 bit bitmap (ie8g or ie8p PixelFormat) which will contain a bitmap with the differences.

Images must have same size and have PixelFormat=ie24RGB.

See 'motiondetector' example for more info.

Example
Eq := ImageEnView1.CompareWith( ImageEnView2.IEBitmap, nil );

William Miller
Adirondack Software & Graphics
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: