• Advertisement
Sign in to follow this  

bounding sphere, or axis aligned bounding box?

This topic is 4799 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

ok. i know very little about directX. i have to have, within the next few days a simple project working of a charachter in a room. all the charachter has to do is to move around and not hit walls and avoid other charachters. im trying this using axis alligned bounding box, but since im not good at maths at all, its taking me a long time to get my head around. should i just do a bounding sphere colission detection instead? anyone offer any help or solution ideas?im not asking anyone to do my project, just want a little help in the right direction. i cannot really understand c++ code, so if you can help me using c# at all it would be terriffic. thank you.

Share this post


Link to post
Share on other sites
Advertisement
Bounding sphere detection is very simple and cheap, so you should use it in addition to another technique. If the sphere test goes without any intersection, then you can skip the other tests.

Share this post


Link to post
Share on other sites
Quote:
Original post by MikeyO
Bounding sphere detection is very simple and cheap, so you should use it in addition to another technique. If the sphere test goes without any intersection, then you can skip the other tests.


Exactly. Usually, the tests go something like this:

(1) Bounding Sphere or Bounding Box
(2) Axis-Aligned Bounding Box
(3) Triangle-Level Collision Detection

Obviously, triangle-level detection is going to take the longest, since a ray test has to be done on each triangle in the mesh. However, it's 100% accurate (or as accurate as you can get, I guess).

Here are some helpful links that will hopefully help you out with the math and programming side of things:

Flipcode Tutorial
Collision Algorithms <-- Great site
More Algos

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement