Writing a Collision Engine for my game

I was having trouble finding a BSD/zlib/public domain collision engine for my game.
So, I wrote my own. You can probably tell I looked at SDL_Collision’s functions before implementing it.

My testing with it has so far been only with static objects that I know for certain are either supposed to collide or not collide.

As for the design, it’s really simple. It spawns a new thread, you create your collision objects and set them up, then in your main loop you signal the thread to begin checking for collisions. This way, you can have the thread idle when there’s no need to check collisions (IE, during a storyline event video) to keep CPU use and battery drain down a little. It also allows you to time all collision detections, so it doesn’t for example interfere with your game logic.

It uses a 3D object called “Rectangular Prism” to represent the parts of the whole object in 3D space. This is faster than using vertex calculations (in case that the graphics are also 3D) and also faster than pixel-perfect in 2D. That’s why I chose this. A description of what a rectangular prism actually is can be found in the header file above the definition of the structure. Example images can be found on Google.

Anyway, here’s the source code as it is right now. I’m releasing it into the public domain as it is fairly simple. Hopefully people will get a look at it, test it, and tell me how I can better it – this is new ground for me.
collide.h: http://pastebin.com/SrVaJUbm
collide.cpp: http://pastebin.com/scyKsAH4