I have to make a python function as callback of a c++ function.How to
do?Where can I find some examples?? I want to use boost.python.
I want my code look something like this: In C++ :
typedef void (*MyCallback_t) (CallbackInfo);
> class MyClass
> {...
> void setcallback(MyCallback_t cb);
> ...
> }
And to use it in python :
import mylib
class mypythonclass:
def myCallback(mylib_CallbackInfo):
....
def mywork():
t = mylib.MyClass()
t.setcallback(self.myCallback)
_______________________________________________
Cplusplus-sig mailing list
[email protected]
http://mail.python.org/mailman/listinfo/cplusplus-sig