How to integrate our own libraries?, eg for rendering?


How would one go about integrating one’s own libraries into Panda? What are the options available, and what options would work well?

For the purposes of context, for example, I’m building a library to render parametric prims ( … _id=136861 ), which is useful for low-bandwidth streamed environments. How can I combine this library into Panda? Would I need to hardlink to Panda and build Panda from scratch, or is there a faster/easier/neater method?

Also, along similar lines, I have a project at which strives to make an OpenSource metaverse. Currently we’re using C++, but I cant help thinking that it could be interesting to use Panda as our “glue” layer, and bolt on appropriate libraries, such as network, object persistence and so on to make it work.

What options could be available for this? How well could this work?

Hugh Perkins

There are two ways I can think of to integrate a library with Panda.

The first way you have already suggested: rebuild Panda “from scratch”, with a bit of new C++ code to interface with your library. This will be necessary, for instance, in the case of your parametric primitive renderer; anything low-level like this will have to be shimmed in to the low-level C++ layer. However, building Panda should not be considered a challenge, especially if you are already used to working with C++.

The second way makes sense for higher-level support libraries, such as networking tools, joystick controllers, and the like; these sorts of things, which are designed to be called directly by the application code, might be easily integrated with Python by using any of a number of Python tools for this purpose (such as SWIG, Boost, or coding Python wrappers by hand). Also, many such third-party libraries may already come with Python wrappers. And once integrated with Python, of course, you can use it in your Python-written Panda application.


The manual does say that building panda is hard. However, things have improved a lot lately. It’s not that difficult anymore. At the ETC, some non-programmers (ie, 3D artists) have succeeded in building panda.

Ok, that sounds reasonable.