How to detect if the image contains the given object or area or these two images are the same in OpenCV

560 views Asked by At

I want to check if the image contains the given part (a small image in side it) or these two image are the same. For better understanding my question look to image bellow.

  1. The image which I am looking for inside another images: enter image description here

  2. Some other images: enter image description here enter image description here enter image description here enter image description here

These images are not the same size. As we look to images above the first, third and forth images containing the given image.

So I have tried three ways to do this: 1. The first way is using OpenCV norm function which is in OpenCV Core class. 2. The second way is comparing histograms of images. 3. The third way is using the algorithm FAST and ORB.

But no one was worked better for me, the first way was working when two images are very the same to each other. The second way was working when two images are almost the same. The third way also was working when the part of images are very the same.

So I cannot get good result using above ways.

If anyone can tell how to do this.

Note: I am using OpenCV 3 in Java, SURF and SIFT not supported.

Thanks in advance!

0

There are 0 answers