Fx2D
A C++20 2D rigid-body physics engine
Loading...
Searching...
No Matches
Fx2D C++ API

The reference is organized around how an application uses the engine. Start with the module that owns the problem you are working on; every module contains its related types and functions.

Browse by module

  • World & entities — scene stepping, rigid bodies, contacts, groups, and solver constraints.
  • Geometry & queries — shapes, bounding boxes, the broad phase, and ray/overlap results.
  • Math & arrays — vectors, matrices, fixed-size arrays, and geometric values.
  • Joints & motors — revolute/prismatic joints and position, velocity, or effort control.
  • Renderer — the raylib/ImGui visual loop and coordinate transforms.
  • Input — keyboard, mouse, and headless injection.
  • YAML scene building — loading scenes and constructing entities, shapes, and joints.

Integration first

The generated reference tells you exact declarations. For practical integration guidance—header selection, linking Fx2Dlib, headless use, and renderer setup—return to the Fx2D API guide.

A useful rule of thumb

FxScene owns the world. FxEntity is a body in it. FxShape describes collision geometry. Link your application to Fx2Dlib, then include only the public headers your use case needs.