Given that there didn’t seem to be a modern wrapper for PhysX, I implemented one using SWIG and two evenings of work. My approach is to directly include the SDK headers, with appropriate pre-definitions to make SWIG able to parse the headers, and use a very light touch in special cases. The draw-back is that this generates classes that aren’t as nice as a custom Python wrapper, but the big bonus is that it can very easily update to new versions of the SDK if needed.
The other big plus is that the .i files do not contain any NVIDIA copyright source at all, as they only reference the SDK headers by name, and you need the SDK included to actually build the pyd libraries. For this reason, I’ve placed my source code (the .i files, some simple .h and .py files, and a build script) in the public domain. Have fun!
I have uploaded a ZIP file to my web page. You can download it if you register as a user on the site.
There is a very simple Panda example program (pandatest.py) which shows two cubes colliding with each other and the ground, to prove that it works, but other than that, it’s pretty hot off the press, so I expect there will be some areas of the API that I haven’t gotten around to. Also: I currently wrap Foundation, Physics, Cooking and PhysXLoader, but not any other library, like the Character library.
If you want to try it out, great! If you want to change or contribute something, well, it’s public domain! But you could post a patch on my web page if you don’t want to release your own version.