1
0
Fork 0
mirror of https://github.com/ruby-opencv/ruby-opencv synced 2023-03-27 23:22:12 -04:00

Merge branch 'fix/issues-38_problem_with_match_template_under_opencv_2.4.6'

This commit is contained in:
ser1zw 2013-11-09 00:55:44 +09:00
commit 0d1efe7893

View file

@ -15,7 +15,7 @@ match_image_filename = (ARGV.size == 2) ? ARGV[1] : File.expand_path(File.dirnam
template = CvMat.load(template_filename)
match_image = CvMat.load(match_image_filename)
result = match_image.match_template(template)
result = match_image.match_template(template, :sqdiff_normed)
pt1 = result.min_max_loc[2] # minimum location
pt2 = CvPoint.new(pt1.x + template.width, pt1.y + template.height)