to rotate template image and perform template matching

匆匆过客 提交于 2021-02-10 15:51:57

问题


I want to rotate given template image at different angles (eg. 30, 60, 90, ...) and then I want to match the rotated images with a source image to detect objects using opencv functions (I'm writing C code)...

How can I do this using opencv functions? Or is there any other solution?

ya i'd searched SOF and that function is not passing rotated image to the main progrm. . . . . and the other code given in SOF continuously rotating the image. so using this we cant do teplate matching.

is there any other codes to solve this problem?


回答1:


Template matching is not a good choice to match rotated targets.

You better check the openCV module Features2D. You'll want to take a special look at the examples for the Feature Matching and Homography. Both contains the functional source.

For furthers details and a great explanation on the topic you can check Innuendo's answer to a similar question here: scale and rotation Template matching



来源:https://stackoverflow.com/questions/9358139/to-rotate-template-image-and-perform-template-matching

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!