Jump to content
  • Advertisement
Sign in to follow this  
crazedfool

Wrap member function to boost python object

This topic is 4049 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm having some trouble in a program I've written that uses python to script most of a simple GUI using boost python. Now I'd like some of the C++ to also be able to register callbacks. All of the callbacks are stored as boost::python::objects. It seems like there has to be a simple way to wrap a bound member function into this object type but after a couple of hours looking I can't seem to come up with it. I've found the function make_function here which will wrap member function pointers however it won't bind them to an actual object instance. Is there any way to bind the callable object returned by make_function to an actual instance, or is there some other way I need to go about this? Thanks in advance.

Share this post


Link to post
Share on other sites
Advertisement
Going to try bumping this just once. It seems like there has to be a simple way to do this. Any help is greatly appreciated.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!