How is Panda3d wrapping C++ with Python?

I am curious how Panda3d wraps the C++ backend with Python. We are also combining both languages in one of our products, using boost::python. So I am wondering: where can I find more information how this is achieved in Panda3d?

We use our own tool, called interrogate, which is part of the Panda source code. It’s poorly documented and sometimes not easy to work with, but so far, it has served us well. It can generate native Python wrappers, which means that it has better performance than generators such as SWIG. A bit more info about it is here:

We’ve considered switching to boost::python, but after further evaluation there were several things we didn’t like about it, most notably the runtime dependency on libboost_python, the bloated wrappers, and the long compilation times.

We would like to switch away from Interrogate at some point to remove the burden of maintenance, but so far I have not found an alternative yet that meets our needs (PyBindGen comes very close, though).

Thanks for your quick reply!

you can also try using cython. I have used it a little bit in a project I was working on. It’s kinda hard to get things to work but after you figure everything out its not that bad.

read this blog post as a starting point

I once wrote a tutorial about Interrogate, maybe it helps you