I need to implement a fast function for detecting collision between a square and circle ... it is also given that square is also axis(X-Y) aligned ..
The center of the circle , square , and the side of the square are known.
The method which is currently use .. (checking all corners and distance between centers) is a bit slow ..
Can any 1 help ?
Even a small suggestion would do .
Jack, I believe this has been posted on frequently in the Game Programming forum. Click on our "General programming Boards" link at the top left side of this page, and check that out.
I've come up with a function that seems to be working .. . Is there any way to test it .. is there any standard library available ? or a list of test cases probably ?
Jack, I thought this was a worthwhile link on the subject:
It includes discussion/some math/ C source code and demo's.