RC RANDOM CHAOS

Box2D creator ships Box3D, an open-source 3D physics engine

· via Hacker News

Original source

Box3D, an open source 3D physics engine

Hacker News →

Erin Catto, the author of the widely used Box2D physics library, has released Box3D, a 3D physics engine now available on GitHub. It began as a fork of Dirk Gregorius’s hobby version of Valve’s Rubikon engine, hooked directly into Unreal, but over time Catto swapped most of its APIs, data structures, and algorithms for Box2D code — keeping the 2D and 3D codebases nearly identical for maintainability. The result shares Box2D’s architecture (C17 source, C API, sub-stepping solver, continuous collision, SIMD contact solver, multithreading hooks, and cross-platform determinism) while adding 3D-specific features like triangle mesh collision, height fields, and baked compound collision.

The engine grew out of concrete production needs on The Legend of California, a survival game Catto is building at Kintsugiyama. Unreal’s native Chaos physics mishandled falling trees on triangle meshes and lacked gyroscopic torque support, and the game’s server simulates hundreds of thousands of entities, demanding a fast broad-phase Catto didn’t want to outsource to middleware. Custom tech let him optimize for specifics like fast-falling redwoods on voxel terrain and a compound-collision system that cooks a stronghold’s ~50,000 separate meshes into a single loadable shape. A second motive is personal: after building game physics engines since 2004, Catto wanted an open-source home for his 3D work so he stops reinventing it with every job change.

Box3D is still alpha — Catto plans to tag v0.1 and work toward v1.0, with more testing, documentation, and solver improvements to come — but it’s already in use beyond his own game, including Facepunch’s s&box platform, the open-source Esoterica engine, and Glenn Fiedler’s 1,000-player space game. Notably, Catto frames it as a labor of love rather than a business, and Kintsugiyama agreed to let him develop and maintain it as part of his day job.

Read the full article

Continue reading at Hacker News →

This is an AI-generated summary. Read the original for the full story.