gameloop Namespace
Central game loop orchestration module. More...
Definition
Classes Index
| class | GameLoop |
|
Central orchestrator for the game update cycle. More... | |
| class | Pass |
|
Abstract base class for game loop passes. More... | |
| class | PassCommitListener |
|
Interface for receiving notifications when a pass reaches its commit point. More... | |
| class | Phase |
|
Represents a phase in the game loop containing multiple passes. More... | |
| class | TypedPass<StateType> |
|
State-filtered pass that only executes in specific states. More... | |
Enumerations Index
| enum class | CommitPoint : uint8_t { ... } |
|
Flags defining synchronization actions at the end of a pass. More... | |
| enum class | PhaseType { ... } |
|
Enumeration of game loop phase types. More... | |
Operators Index
| CommitPoint constexpr | operator& (CommitPoint a, CommitPoint b) noexcept |
|
Bitwise AND operator for CommitPoint flags. More... | |
| CommitPoint constexpr | operator| (CommitPoint a, CommitPoint b) noexcept |
|
Bitwise OR operator for CommitPoint flags. More... | |
Description
Central game loop orchestration module.
Provides the GameLoop, Phase, and Pass classes for managing phased system execution with deterministic ordering and event synchronization.
Enumerations
CommitPoint
| strong |
Flags defining synchronization actions at the end of a pass.
- Enumeration values
A CommitPoint specifies what operations should be performed when a pass completes. Multiple flags can be combined using bitwise OR to trigger several actions at once.
Commit points are essential for the deterministic ordering of the game loop:
- Commands are queued during passes and executed at commit points
- Pass-level events become readable only after a commit
- Managers process their queued requests at commit points
Example usage: ```cpp pass.addCommitPoint(CommitPoint::PassEvents | CommitPoint::FlushCommands); ```
- See Also
- See Also
GameLoop::passCommit()
Definition at line 35 of file CommitPoint.ixx.
PhaseType
| strong |
Enumeration of game loop phase types.
- Enumeration values
-
Pre Pre-update phase for input and command processing Main Main update phase for core gameplay systems Post Post-update phase for cleanup and scene synchronization
The game loop is divided into three sequential phases:
- **Pre:** Input processing and command generation.
- **Main:** Core gameplay simulation (physics, AI, game logic).
- **Post:** Synchronization, cleanup, and preparation for rendering.
Operators
operator&()
| constexpr noexcept |
Bitwise AND operator for CommitPoint flags.
- Parameters
-
a First operand.
b Second operand.
- Returns
The combined flags.
Definition at line 83 of file CommitPoint.ixx.
operator|()
| constexpr noexcept |
Bitwise OR operator for CommitPoint flags.
- Parameters
-
a First operand.
b Second operand.
- Returns
The combined flags.
Definition at line 95 of file CommitPoint.ixx.
The documentation for this namespace was generated from the following files:
Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.