Here you can find the C++ tutorials I have done. They contain descriptions, diagrams and sample code.
Collision Tutorials:
| Half Space Test (point on plane) A simple test to find out the position of a point respective to a plane. |
|
| Point in AABB Finding out whether a point is inside or outside an Axis Aligned Bounding Box (AABB). |
|
| AABB to AABB A quick test to find out if two Axis Aligned Bounding Boxes are colliding. |
|
| Point in Sphere Finding out whether a point is inside or outside a sphere. |
|
| Sphere to Sphere A test to find out if two spheres are colliding with each other. |
|
| Sphere to Plane A test to find out if a sphere is colliding with a plane. |
|
| Ray to Sphere A test to find out if a ray collides with a sphere. There are two versions of this algorithm, a version that calculates the time of collision and a version that doesn’t. |
|
| Moving Sphere to Static Sphere A test to figure out if and when a moving sphere collides with a static sphere. |
|
| Moving Sphere to Containing Sphere’s Edge A test to figure out if and when a contained moving sphere collides with the edge of a containing sphere. |
Mathematics and Physics
| Distance between two points on a sphere A way of calculating the distance between two points using cartesian coordinates (xyz) instead of the great-circle distance formula. |