I trying to compile information on various ways todo collision detection and pros/cons of each method.
I was creating simple demo of balls boucing around and colliding with each other (see http://grom358.mygamesonline.org/bouncingballs.html
and explaination at http://grom358.mygamesonline.org/bouncingballs_guide.html
). I believe this is what is known as a sweep test cause it finds out if and when objects collide.
Pros: Always detect collisions
Cons: Sweep tests get more complex for other shapes
The other I am aware of at the moment is to make small steps in time and test if the objects overlap.
Pros: Do not have to deal with dynamic movement of object in collision detection code
Cons: Fast or small moving objects detections can be missed cause they collide in between the time steps