Advertisement

Collision Detection ?

Started by March 09, 2000 04:14 AM
3 comments, last by Crypthor 25 years ago
can somebody help with Collisions? There is a faster way to detect collision with objects in OGL? This stuff i can''t solve, with out your help !!! Thank You !
Cryp
Bounding spheres. Pick a size (radius) for an imaginary "bounding" sphere to follow each entity. For each entity you want to check for collisions between, simply see if they''re within a certain range (in this case, the sum of their bounding spheres'' radii).
Advertisement
what do you do after the bounding sphere test?
do you check each polygon from one object with the other object?
It depends on how accurate should be your collision detection algorithm.
Collision detection is one of the most difficult topic in computational geometry...
You can use bounding spheres or bounding box...
If you use simple objects you can use bounding sphere; if you''re using complex objects it''s better to use hierarchical bounding boxes...
Finally you have to check for collision for every polygon
of one object and the other.
Remember to store your objects in a matrix or in an octree so it''s simple to know if there are objects to check.
IpSeDiXiT
Like Andrea said, it all depends on the objects you''re checking and the desired level of accuracy. Bounding spheres should be used with simple objects and hierarchial bounding boxes with more complex ones. But you don''t necessarily have to check any polygons or anything as long as you''ve defined your bounding boxes with enough detail for your purposes. Now, if you want *perfect* collision detection, check the polygons and their vectors, right? =)

This topic is closed to new replies.

Advertisement