I am trying to find an image in another.
im = cv.LoadImage('1.png', cv.CV_LOAD_IMAGE_UNCHANGED) tmp = cv.LoadImage('e1.png', cv.CV_LOAD_IMAGE_UNCHANGED) w,h = cv.GetSize(im) W,H = cv.GetSize(tmp) width = w-W+1 height = h-H+1 result = cv.CreateImage((width, height), 32, 1) cv.MatchTemplate(im, tmp, result, cv.CV_TM_SQDIFF) print result
When I run this, everything runs fine, no errors occur. But I'm not sure what to do next. Doc says that result
stores a "map of comparison results." I tried to print it, but it gives me width, height and pitch.
How to use this information to determine if one image is in another / where is it located?
source share