I'm trying to make a simple game. I have some items in QGraphicsView, and I'm trying to make a ball to bounce off of them. Here's the problem: I can detect when a collision happens, but I don't know in which direction the ball should bounce. For that I would need to find out the tangent of the surface of the item. The items can be of any shape, and the collision should look physically correct. Any help appreciated.