collsion detection
Be a little more specific. Collision detection between what? Sphere's, poygoons, 2D, 3D, object pairs or many objects?
Quote:Original post by phil67rpg
well it is between a paddle and ball for a breakout game, I am using c++ and open gl
my old project done 4 years ago, in C/OpenGL (not perfect but should enough)
:)
You should be able to do simple bounding box detection.
Do a few google searches for bounding box and to be more specific "axis aligned bounding boxes".
The general idea is you keep track of the 4 corners of each rectangle then if you want to check for a collision you just see if the extents of one rectangle are in the boundaries of a second rectangle. If they are then you have a collision.
It can be done with simple math and is very easy to do.
Do a few google searches for bounding box and to be more specific "axis aligned bounding boxes".
The general idea is you keep track of the 4 corners of each rectangle then if you want to check for a collision you just see if the extents of one rectangle are in the boundaries of a second rectangle. If they are then you have a collision.
It can be done with simple math and is very easy to do.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement