Skip to content

Collision detection and response library for Circle-circle and Polygon-polygon collisions

License

Notifications You must be signed in to change notification settings

shubhsharma10/2DCollisionLibrary

Repository files navigation

2D Collision Library

Description

The core idea of the project was to build a physics engine to simulate object in space, based on collision detection and collision resolution patterns.

  1. A polygon collision detection system
  2. A circle collision detection and resolution system

Instructions

  • Run the CollisionLibraryDemo.py file using a Python compiler
  • To access the two different modes, use number keys 1 and 2
  • To add polygons/circles press 'A'
  • To display the quad tree division, press 'D'
  • To reset the simulation, press 'R' Note : Make sure Pygame is installed

Website

Build (binary file)

Algorithms used

  • Seperating Axis Theorem
  • Welzl's algorithm for minimum bounding circle