Cannot get SURF example in EMGU.CV to work?

痞子三分冷 提交于 2019-12-25 06:44:53

问题


I am trying to detect a pattern shown in two images. Hence I have been trying to use the SURF algorithim found in emgu.CV, but the "SURFFeature" example that is given gives me the following error:

    An unhandled exception of type 'Emgu.CV.Util.CvException' occurred in Emgu.CV.dll

Additional information: OpenCV: norm == NORM_L1 || norm == NORM_L2 || norm == NORM_HAMMING

Any ideas how to fix this?

When I try the "Hello World" example and the face detection example, both seem to work fine.

Thanks for any advice!

Fouad.

PS: Emgu.CV can be downloaded from here: http://www.emgu.com/wiki/index.php/Main_Page


回答1:


Apparently the build was messed up.

http://www.emgu.com/bugs/show_bug.cgi?format=multiple&id=74

Aha, found it. The error here is in Emgu.Cv.Gpu/GpuBruteForceMatcher.cs lines 22 and 27.

Line 22 currently reads: L2Dist,

It should read: L2Dist = 4,

Line 27 currently reads: HammingDist

It should read: HammingDist = 6

Rebuild the Emgu.CV.Gpu dll with those changes and it works.



来源:https://stackoverflow.com/questions/15643762/cannot-get-surf-example-in-emgu-cv-to-work

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