EnTT is a C++ library designed for data-oriented design and entity component system architecture. It provides a framework for managing game objects and simulation states by separating entity data from logic, allowing for the efficient organization and manipulation of large collections of related data objects.
The library utilizes sparse sets to store entities and components in contiguous memory, which facilitates cache-friendly iteration and constant-time lookups. It employs template metaprogramming for compile-time type reflection and type-erasure techniques to provide a unified interface for heterogeneous component types. Developers can further customize memory layout and allocation through policy-based component management.
The system includes reactive observers that monitor component lifecycles to trigger callbacks automatically during creation, update, or destruction events. These capabilities support high-frequency simulation updates by enabling parallel iteration over component pools, which minimizes branching and maximizes CPU cache efficiency.