Search code examples
javaopencvjavacv

Object Finding with the help of javaCV


The program to find the presence of an object in an image using the JavaCV ObjectFinder class is working well when the input images are almost the same size.

But that same code, using a smaller image containing an object and the bigger image containing a scene, is not working.

The following exception occured:

OpenCV Error: Assertion failed (src.depth() == dst.depth() && src.size == dst.size) in unknown function, file ..\..\..\src\opencv\modules\core\src\copy.cpp, line 557

How can I solve this?


Solution

  • It is the drawback of ObjectFinder class provided by javacv.The input images must be in almost same size and depth in order to compare and find the presence of an object in a scene.I got this after several experiments.