How to bind to OpenCV for GNAT?

余生长醉 提交于 2019-12-18 09:08:46

问题


Can anybody tell me how to find or create a binding to OpenCV for GNAT? I want to use Ada2005 to implement some program with OpenCV (1.0 or 2.X), but I don't know how. Can anybody teach me how to do it?


回答1:


Teaching you how to create a binding to a complex library is beyond the scope of StackOverflow, but you might start with this tutorial. Then study the relevant GNAT library sources, e.g. Ada.Numerics, and other existing Ada bindings. Among others, Ada 2005 Math Extensions and An Ada binding to the GNU GMP and MPFR Multiple Precision libraries are exemplary as well as accessible.




回答2:


If you have Gnat Pro (and presumably a support contract from ACT), I think you can get a binding generator from them.

In the comments, Simon Wright pointed out that you can get this binding generator from GCC 4.6.0., which is the official (although sometimes a bit behind) GCC distribution. I generally suggest folks who aren't paying ACT customers get their compiler from GCC, rather than the GNAT GPL version from ACT.



来源:https://stackoverflow.com/questions/6928285/how-to-bind-to-opencv-for-gnat

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