@@ -12,11 +12,12 @@ Box2D is a 2D physics engine for games.
1212
1313### Collision
1414- Continuous collision detection
15- - Contact events and sensors
15+ - Contact events
1616- Convex polygons, capsules, circles, rounded polygons, segments, and chains
1717- Multiple shapes per body
1818- Collision filtering
1919- Ray casts, shape casts, and overlap queries
20+ - Sensor system
2021
2122### Physics
2223- Robust _ Soft Step_ rigid body solver
@@ -31,19 +32,22 @@ Box2D is a 2D physics engine for games.
3132- Data-oriented design
3233- Written in portable C17
3334- Extensive multithreading and SIMD
35+ - Optimized for large piles of bodies
3436
3537### Samples
3638- OpenGL with GLFW and enkiTS
3739- Graphical user interface with imgui
3840- Many samples to demonstrate features and performance
3941
40- ## Building
42+ ## Building for Visual Studio
4143- Install [ CMake] ( https://cmake.org/ )
4244- Ensure CMake is in the user ` PATH `
43- - Visual Studio: run ` build.bat ` from the command prompt
44- - Otherwise: run ` build.sh ` from a bash shell
45+ - Run ` create_sln.bat `
46+ - Open and build ` build/box2d.sln `
47+
48+ ## Building for Linux
49+ - Run ` build.sh ` from a bash shell
4550- Results are in the build sub-folder
46- - On Windows you can open box2d.sln
4751
4852## Building for Xcode
4953- Install [ CMake] ( https://cmake.org )
@@ -52,15 +56,25 @@ Box2D is a 2D physics engine for games.
5256- mkdir build
5357- cd build
5458- cmake -G Xcode ..
55- - open box2d.xcodeproj
59+ - Open ` box2d.xcodeproj `
5660- Select the samples scheme
57- - Edit the scheme to set a custom working directory to the box2d directory
58- - You can now build and run the samples
61+ - Build and run the samples
62+
63+ ## Building and installing
64+ - mkdir build
65+ - cd build
66+ - cmake ..
67+ - cmake --build . --config Release
68+ - cmake --install . (might need sudo)
5969
6070## Compatibility
6171The Box2D library and samples build and run on Windows, Linux, and Mac.
6272
63- Box2D should be built on recent versions of clang and gcc. You will need the latest Visual Studio version for C11 atomics to compile (17.8.3+).
73+ You will need a compiler that supports C17 to build the Box2D library.
74+
75+ You will need a compiler that supports C++20 to build the samples.
76+
77+ Box2D uses SSE2 and Neon SIMD math to improve performance. This can be disabled by defining ` BOX2D_DISABLE_SIMD ` .
6478
6579## Documentation
6680- [ Manual] ( https://box2d.org/documentation/ )
@@ -73,7 +87,7 @@ Box2D should be built on recent versions of clang and gcc. You will need the lat
7387Please do not submit pull requests. Instead, please file an issue for bugs or feature requests. For support, please visit the Discord server.
7488
7589# Giving Feedback
76- Please file an issue or start a chat on discord.
90+ Please file an issue or start a chat on discord. You can also use [ GitHub Discussions ] ( https://github.com/erincatto/box2d/discussions ) .
7791
7892## License
7993Box2D is developed by Erin Catto and uses the [ MIT license] ( https://en.wikipedia.org/wiki/MIT_License ) .
@@ -83,7 +97,7 @@ Support development of Box2D through [Github Sponsors](https://github.com/sponso
8397
8498Please consider starring this repository and subscribing to my [ YouTube channel] ( https://www.youtube.com/@erin_catto ) .
8599
86- ## Ports , wrappers, and bindings
100+ ## External ports , wrappers, and bindings (unsupported)
87101- Beef bindings - https://github.com/EnokViking/Box2DBeef
88102- C++ bindings - https://github.com/HolyBlackCat/box2cpp
89103- WASM - https://github.com/Birch-san/box2d3-wasm
0 commit comments