|This article relies too much on references to primary sources. (January 2015)|
|Initial release||September 11, 2007|
|Stable release||2.3.1 / April 5, 2014|
|Operating system||OS independent|
Box2D is a free open source 2-dimensional physics simulator engine written in C++ by Erin Catto and published under the zlib license. It has been used in Crayon Physics Deluxe, Limbo, Rolando, Fantastic Contraption, Incredibots, Angry Birds, Tiny Wings, Transformice, Happy Wheels, and many online Flash games, as well as iPhone, iPad and Android games using the Cocos2d or Moscrif game engine and Corona framework.
Box2D was first released as "Box2D Lite", a demonstration engine to accompany a physics presentation given by Erin Catto at GDC 2006. On September 11, 2007 it was released as open source on Sourceforge. On January 17, 2010 Box 2D moved the project to Google Code for hosting.
Box2D is itself written in platform-independent C++ (usable on any system with a C++ compiler available). The engine may be compiled in fixed point and floating point modes, and has been used on the Nintendo DS, Wii, and several mobile phones (including Android, BlackBerry 10 and iPhone) as well as most major operating systems.
Programs that use the engine
- ENIGMA Development Environment
- GameMaker: Studio, uses the engine for physics simulation.
- Godot, uses the engine for physics simulation.
- Löve, with a Lua binding
- LibGDX, uses the physics engine for games and Lighting.
- Stencyl, uses the physics engine for games, and allows export to Flash and iOS.
- Isogenic Engine
- Clickteam Fusion
Box2D performs constrained rigid body simulation. It can simulate bodies composed of convex polygons, circles, and edge shapes. Bodies are joined together with joints and acted upon by forces. The engine also applies gravity, friction, and restitution.
Box2D's collision detection and resolution system consists of three pieces: an incremental sweep and prune broadphase, a continuous collision detection unit, and a stable linear-time contact solver. These algorithms allow efficient simulations of fast bodies and large stacks without missing collisions or causing instabilities.
An earlier version of the Box2D engine, now known as Box2D Lite, was released primarily for educational purposes, based on a series of yearly Game Developers Conference presentations that Erin Catto has given. Box2D Lite uses many of the same algorithms as Box2D, but has a smaller feature set.
The physics engine used in SpriteKit for iOS and OS X uses Box2D internally.
- on GitHub
- Box2D Main Page
- "Play Happy Wheels Online - AndroidFantasy". Retrieved 14 August 2015.
- Jay is Games
- Box2D Blog, as cached by the Wayback Machine
- JBox2D website
- Box2DFlash on SourceForge
- Physaxe on Google Code
- Box2DX on Google Code
- Box2DJS on SourceForge
- Box2DWeb on Google Code
- Blaze on dsource
- Pybox2d on GitHub
- Torque 2D Development Blog
- Box2D Manual
- Chipmunk on Google Code
- Phys2D engine website
- Steffen Itterheim. (2010). "Learn iPhone and iPad cocos2d Game Development." Apress.
- Rod Strougo and Ray Wenderlich. (2011). "Learning Cocos2d: A Hands-On Guide to Building IOS Games with Cocos2d, Box2d, and Chipmunk." Addison-Wesley Professional.
- Adobe Edge April 2010