Question

I have a C++ GUI, it load a DLL when running. I use SIP to import the DLL in python. I need to embed the python part in the GUI, and some data are needed to exchange between python and C++.

For example, in the C++ GUI, I can enter command from a panel, such as "drawSomething()", it will call corresponding function in python, and the result will be shown in the GUI.

Can I use SIP to extract a C++ object from python object (just like the way boost.python does), or is there a better way to share data between python and c++ seamlessly?

thanks.

Was it helpful?

Solution

It turns out that I do not need to do anything complicated... In my case, there is no difference to call functions in DLL from C++ or from python code embedded in C++. I am totally over-thinked.

OTHER TIPS

Please take a look at this Library

http://www.swig.org/Doc1.3/Python.html

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top