Polygon Body Collision Response

Jun 9, 2009 at 10:16 AM

Hello to anyone that can help its not nessecarily for the people working on farseer,

but currently i am attempting to do my collision detection and response for an isometric game,

I have my collision detection working,

its basically a rectangle to be a sort of perform broad phase,

then vertices for a type of narrow phase (im not sure if im using broad and narrow phase correctly here hehe)

But anyway the process for narrow phase checks if the polygons contains any points of the other geomoetry,

then checks if any segments are intersecting,

my question is how would i program a collision response to this,

at first i took the vertices(vector2 array) contained by the static geometry and the vertices contained by the dynamic geometry,

get the highest Vector2 for each vertice array then modify the position of the dynamic geomtry by the difference of the two.


In theory this sounded correct but in practice it doesnt work in the slightest,

I looked through your project for some info but found the only narrow phase collider you use now is SAT and the rest are broad phase,

can anyone inform me on how i could use the information obtained through my technique to trigger an atleast somewhat accurate response,

and it doesnt need to take into account rotation

Oct 4, 2009 at 10:39 PM

There are different ways of calculating the physics response. It depends on the type of engine. We have both a distance grid (Signed distance field) and SAT as narrow phase colliders. We calculate the physics response from using an impulse based engine type (we got that from Box2D lite). A good introduction to physics response can be found here. I'm also writing an introduction to a physics engines starting with the overview of components.