PixelPerfect
A simple pure python implementation of an pixel perfect collision detection algorithm.
John Eriksson
(wmjoers)
A simple pure python implementation of an pixel perfect collision detection algorithm.
When starting the example 200 sprites is added to the screen at random locations. You can then move a larger blue sprite around by using the arrow keys or by using the mouse. Press spacebar to toggle between the pixelperfect-algorithm and the regular rectangle based one.
Whenever a hit is detect it is indicated by the BOOOM! text.
There is a bug in the current PyGame release that prevents this example from working. But if you check out the latest PyGame version from CVS it should work just fine!
When starting the example 200 sprites is added to the screen at random locations. You can then move a larger blue sprite around by using the arrow keys or by using the mouse. Press spacebar to toggle between the pixelperfect-algorithm and the regular rectangle based one.
Whenever a hit is detect it is indicated by the BOOOM! text.
There is a bug in the current PyGame release that prevents this example from working. But if you check out the latest PyGame version from CVS it should work just fine!
Changes
Links
- Home Page
- http://arainyday.se
Releases
PixelPerfect 1.0 — 2 Mar, 2006