## Problem with collisions at "t-joints"

Official forum for the Chipmunk2D Physics Library.
DangerCode
Posts: 3
Joined: Mon Sep 17, 2007 11:46 pm
Contact:

### Problem with collisions at "t-joints"

I'm wondering how I can solve the problem that is detailed with the following picture.

I have a ball that I want to bounce along a surface. This works great most of time, but I do have some geometry that meets together at a T-JOINT, and often the ball won't bounce as expected (like it is striking a smooth surface, in the top example) but instead will appear to collide with the inside edge of the red rectangle and bounce backwards (like in the bottom example).

What's the best way to compensate for this? I imagine I want to throw out the collision between the ball and the red rectangle, but I'm not sure how to reliably handle this.

Thanks.
slembcke
Posts: 4164
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

### Re: Problem with collisions at "t-joints"

Unfortunately I don't know either. I assume the ball is moving pretty fast for that to happen? In a perfect world, I'd be smart enough to implement swept collisions. You could try decreasing the timestep, but that will certainly eat up more CPU.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
DangerCode
Posts: 3
Joined: Mon Sep 17, 2007 11:46 pm
Contact:

### Re: Problem with collisions at "t-joints"

FWIW, I've liked Olivier's swept collision examples and documentation using the Axis of Separation method. I've used AoS in my own game engine and it works well for me but really impresses me about Chipmunk is the speed and the addition of rigid body physics (I only have collision detection in my own library, and I can't handle 100's of collisions like you can).

http://uk.geocities.com/olivier_rebellion/
(click on 2D swept+overlap polygonal collision and response)

### Who is online

Users browsing this forum: No registered users and 13 guests