Calling C++ DLLs from Python

后端 未结 2 577
既然无缘
既然无缘 2021-02-09 18:17

I\'d like to know if it is possible to use ctypes to access C++ DLLs from Python and run functions (or class methods) from them.If not, is there another way to do this?

2条回答
  •  伪装坚强ぢ
    2021-02-09 19:14

    the boost python library makes it REALLY easy to wrap a C++ class and expose it as python module. It took me around 10 minutes the first time I tried.

    http://www.boost.org/doc/libs/1_42_0/libs/python/doc/tutorial/doc/html/index.html

提交回复
热议问题