PhysX is a 3D game physics engine provided by NVIDIA. They have released the source code of the engine on Github, though with restricted access. This library and its sample programs can be compiled from source easily.
Here are my notes on how to compile this library, run its sample tools and get started:
- You need a Linux computer (I use Ubuntu), with a fairly modern NVIDIA graphics card.
Make sure you have installed recent NVIDIA graphics drivers and a recent version of CUDA on it. Ensure that these are working correctly before trying PhysX.
Go to this webpage and jump through their hoops to get access to the PhysX Github page. Essentially, NVIDIA requires you to create a login with them and after that they give your Github login the access to their PhysX source code.
Once you have access to PhysX source code, clone its repository to your computer:
$ git clone https://github.com/NVIDIAGameWorks/PhysX-3.3.git
The documentation in the source code is outdated and is misleading. This is how the source code is laid out:
Sourcefor source code,
Sampleshave small programs to try PhysX. Once you have compiled these Snippets and Samples, their binaries will be placed in
Each of the above three code directories has a
compiler/linux64directory which holds the Makefiles to build them. There are four build profiles available:
debug. Just invoking
makebuilds all four versions. To build just the release versions, I did
make releasein all the three code directories.
Once the library and its snippets and samples are built, you can try these programs from
Bin/linux64. For example, the
samplesprogram allows you try many of the features of the engine in an interactive GUI.
Tried with: PhysX 3.3.4, NVIDIA GeForce GTX 750 Ti and Ubuntu 14.04