Archive for the ‘Uncategorized’ Category

Predicting circle line collisions

Tuesday, January 19th, 2010

IMG_8179

In my previous collision detection post (in what I expect will become a series), I talked about predicting whether two objects would collide in between frames. This is to avoid the situation where the objects are moving so fast that they pass through each other before you’ve had a chance to see if they’re overlapping. This is often known as a sweep test (amongst other things!)

And I showed how you could predict collisions between a 2D circle and a vertical line but what about lines that aren’t vertical? How do you work out collisions between circles and lines of any angle?

(more…)

Bad Behavior has blocked 2871 access attempts in the last 7 days.