[C++-sig] In a C++ extension, how to use a C++ class exported in another extension
Hua Su
suh at mails.tsinghua.edu.cn
Thu May 12 06:46:19 CEST 2005
Hi,
I'v learnt Boost.Python for two weeks and now encounter some problems :(
In brief, I can't find the way to use a C++ class, which is exported in an
existing extension, in another extension written by myself.
In detail, I'm writing a paint program with wxPython which is an
extension for GUI library wxWidgets (wxWindows). I use wxPython to implement
GUI, and use C++ to implement paint operations.
( In my application the paint operations is a bottleneck so I have to implement
is in C++ )
When painting, I need to pass a pointer of DC from Python to my C++ code.
The problem is, the class "wxDC" is a real C++ class writen in wxWidgets,
and is exported in wxPython as Python class "DC", but I need use it in my
code as C++ class "wxDC". I can't find support from Boost.Python for
this problem. I have tried to pass pointer "void *" instead, but Boost.Python
declares it does not support "void *" as argument or return type.
Could someone give me some example? I work for this problem for days :(
Thanks for your reply.
regards,
Clark
More information about the Cplusplus-sig
mailing list