- Project Title: Gaming Campus Engine Paris
- Version: 1.4
- Date: 2026-02-17
| Author | Contact |
|---|---|
| Morgane Prevost | mprevost@gaming.tech |
| Dylan Hollemaert | dhollemaert@gaming.tech |
| Clément Bobeda | cbobeda@gaming.tech |
| Najim Bakkali | nbakkali@gaming.tech |
| Leo Grognet | lgrognet@gaming.tech |
| Date | Version | Description | Author |
|---|---|---|---|
| 2026-02-17 | 1.4 | Code conventions | [Leo Grognet, Clément BOBEDA, Dylan Hollemaert, Najim Bakkali, Morgane Prevost] |
| 2026-02-04 | 1.3 | Naming Convention, Schematic tweaks and dependencies justification | [Leo Grognet, Clément BOBEDA, Dylan Hollemaert, Najim Bakkali, Morgane Prevost] |
| 2026-02-04 | 1.2 | Document bottom half document fill | [Leo Grognet, Clément BOBEDA, Dylan Hollemaert, Najim Bakkali, Morgane Prevost] |
| 2026-02-03 | 1.1 | Document General improvement | [Leo Grognet, Clément BOBEDA, Dylan Hollemaert, Najim Bakkali] |
| 2026-02-03 | 1.0 | Initial document creation | [Leo Grognet, Clément BOBEDA] |
- Introduction
- System Overview
- Requirements
- System Architecture & Design
- Detailed Module Design
- Interface Design
- Performance and Optimization
- Testing Strategy (TDD Implementation)
- Tools, Environment, and Deployment
- Security and Safety Considerations
- Project Timeline and Milestones
- Appendices
This document outlines the technical design for a modular C++ Game Engine, detailing its architecture, modules, and Test-Driven Development (TDD) approach.
- Objective: Develop a cross-platform, fast and intuitive game engine for rendering, physics, audio, and input management.
- Application: Real-time game development and academic projects.
- TDD: Test-Driven Development
- API: Application Programming Interface
- FPS: Frames Per Second
- IDE: Integrated Development Environment
- GUI: Graphical User Interface
- Gizmo: Gizmo are directly manipulable, self-contained, visual screen idioms
- C++ Standard Documentation
- Google Test Framework
- Mini audio for sound management
- Jolt physics for physics management
- GLM for mathematics
- GLFW for window handling
- ImGui for all GUI handling
- ImGuizmo for the implementation of gizmo
This Technical Design Document (TDD) details the architecture of a high-performance, lightweight game engine specifically tailored for academic environments. The primary goal is to provide a robust yet accessible platform for game design students, balancing low-level technical transparency with high-level usability. To fulfill these requirements, the engine’s design focuses on three core pillars:
-
Performance & Optimization: Leveraging the Vulkan API through a custom RHI (Render Hardware Interface) to ensure a minimal memory footprint and high frame rates on varied hardware.
-
Educational Accessibility: Abstracting the verbosity of modern graphics APIs into a clean, intuitive interface, allowing students to focus on game logic and scene composition rather than hardware-specific boilerplate.
-
Modular Decoupling: A strict separation between the Editor (creation tool) and the Runtime (execution layer). This ensures that students can experiment in a stable environment where game-logic errors remain isolated from the core engine tools.
This document serves as the structural roadmap for implementation, covering module interactions, data flow, and the testing strategies necessary to maintain a stable learning tool.
The engine is built as a layered modular system using C++20. It is architected to decouple high-level game logic from low-level hardware interactions, ensuring both high performance and ease of use for academic purposes.
The system is organized into three primary layers:
-
Application & Tools Layer: The Editor and Runtime environments. The Editor provides a visual interface for scene composition, while the Runtime offers a lightweight execution path for the final game. Both communicate with the core through a unified API.
-
Core Engine : This layer acts as the "brain" of the engine. It manages the Scene Graph (object hierarchy) and dispatches tasks to specialized Servers (Rendering, Physics, Audio).
-
Abstraction Layer (RHI & Drivers): To ensure long-term stability and performance, the engine utilizes a Render Hardware Interface (RHI). This layer translates high-level draw calls into optimized Vulkan commands. This abstraction hides the complexity of Vulkan from the end-user while maintaining "close-to-metal" speed.
graph TB
%% --- ENGINE ---
subgraph Engine [Engine]
direction TB
subgraph Core [Core]
subgraph RHI[RHI]
RenderW[RenderWrapper]
end
PhysW[PhysicsWrapper]
AudioW[AudioWrapper]
end
end
%% --- EXTERNAL ---
subgraph Dependencies [External]
direction LR
subgraph UI_Lib [UI]
ImGui{ImGui}
ImGuizmo{ImGuizmo}
end
subgraph Audio_Lib [Audio]
Miniaudio{Miniaudio}
end
subgraph Physics_Lib [Physics]
JoltPhysics{JoltPhysics}
end
subgraph Math_Window [Math & Window]
GLM{GLM}
GLFW{GLFW}
end
end
%% --- EDITOR ---
subgraph Editor [Editor]
UIW[UIWrapper]
Viewport[Viewport]
end
%% --- LIAISONS LOGIQUES (CONNECTIVITY) ---
%% L'Editor utilise l'Engine et les Libs
Engine --> Editor
UIW --- ImGui
Viewport --- ImGuizmo
%% L'Engine utilise les Libs
Engine --> GLFW
Engine --> GLM
PhysW --> JoltPhysics
AudioW --> Miniaudio
%% --- STYLES ---
style Engine fill:#705c51,stroke:#000,stroke-width:4px
style Dependencies fill:#c2c1a5,stroke:#000, stroke-width:4px
style Editor fill:#c2c1a5,stroke:#000,stroke-width:4px
style Core fill:#677051,stroke:#000,stroke-width:4px
style RHI fill:#517059,stroke:#000, stroke-width: 4px
style Physics_Lib stroke:#000, stroke-width: 4px
style Audio_Lib stroke:#000, stroke-width: 4px
style UI_Lib stroke:#000, stroke-width: 4px
style Math_Window stroke:#000, stroke-width: 4px
- Rendering Engine: Handles graphics using the Vulkan API.
- Physics Engine: Manages collision detection and physics simulations using Jolt Physics.
- Audio Engine: Processes sound effects and music using miniaudio.
- Input Manager: Captures keyboard, mouse, and gamepad events using GLFW.
- Window Manager: Manages application window, dispatches and receive input events using GLFW
- Editor GUI: Graphical user interface using ImGui
- Game Logic: Integrates modules via a scripting interface.
- Render 3D graphics with dynamic lighting and shading.
- Perform real-time physics simulation and collision detection.
- Play background music and trigger sound effects.
- Capture and process user inputs.
- Provide a scripting interface for game behavior customization.
- Supports OBJ parsing.
- Performance: Maintain a minimum of 60 FPS. Smart Pointers, Allocation Pools, Cache-Efficients Structures to achieve an optimized memory management.
- Scalability: Modular design for easy extension. Use of RHI to allow the use of multiple graphics API. Feature proof choice of dependencies and technologies.
- Portability: Support Windows, Linux, and macOS.
- Maintainability: Clear code structure with thorough documentation.
- Quality of Life: Dynamic Asset Loading. ImGui Editor with window docking system and entity and ressources management.
- Rendering: Load and display complex scenes.
- Physics: Update object states and detect collisions.
- Audio: Manage and play audio assets.
- Input: Map user actions to game events.
- Use modern C++ (C++20 or later).
- Use Slang as the primary shader language.
- Rely on hardware-accelerated graphics.
- Assume a minimum hardware configuration for target platforms.
The engine employs an entity component system and a component based architecture. Each module has well-defined interfaces, ensuring loose coupling and isolated development.
- Rendering Module: Handles shaders, textures, and communicates with the GPU. (Vulkan)
- Physics Module: Implements collision detection and rigid body dynamics.(Jolt Physics)
- Audio Module: Interfaces with audio libraries. (miniaudio)
- Input Module: Abstracts device-specific input. (GLFW)
- Game Logic Module: Manages scripting and event coordination. (Core)
- Editor Module: Manages Graphical User interface. (ImGui)
User Input -> Game Logic -> Rendering Module -> GPU
graph
A[Start Loop] --> B[Process Input];
B --> C[Update Game State];
A --> |Fixed Update|D[Update Game Physics];
C --> E[Render];
E --> F[End Loop];
- Language Choice: C++ for high performance.
- Modular Design: Supports isolated testing and independent module development.
- Graphic API: Vulkan is a modern Graphic API and cross-platform allowing us to get the best performances.
- Rendering:
Renderer,Shader,Texture - Physics:
PhysicsEngine,Collider,RigidBody - Audio:
AudioEngine,Sound,MusicPlayer - Input:
InputManager,Keyboard,Mouse,Controller
#include <iostream>
#include "Renderer.h"
int main() {
Renderer renderer;
if (!renderer.initialize()) {
std::cerr << "Renderer initialization failed." << std::endl;
return -1;
}
while (renderer.isRunning()) {
renderer.processInput();
renderer.updateScene();
renderer.renderFrame();
}
renderer.shutdown();
return 0;
}- Utilize exception handling for critical errors.
- Implement a logging system to record runtime events and performance metrics.
- Define clear APIs between modules using abstract classes or interfaces.
- Support standard file formats: OBJ (models), PNG and JPG (textures), WAV, MP3, FLAC (audio).
- Provide documentation for external scripting interfaces.
- Develop a debug UI for real-time performance monitoring and diagnostics.
- Physics Update runs consistently at 60 tick per seconds.
- Consistently achieve 120 FPS.
- Optimize memory usage and processing overhead.
- Integrate Valgrind profiling tool.
- Use object pooling and memory management best practices.
- Implement batching and frustum culling in the rendering process.
- Use of multiple threads on updating different type of loop.
- Use of Entity Component System by grouping each entity updates together in memory.
- Develop tests for individual components.
- Example using Google Test:
#include <gtest/gtest.h>
#include "Renderer.h"
TEST(RendererTest, InitializeSuccess) {
Renderer renderer;
EXPECT_TRUE(renderer.initialize());
}- Verify that modules interact correctly through integration tests.
- Maintain a suite of automated tests to catch and fix regressions early.
- Framework: Google Test
- CI/CD: Automate testing with CI pipelines (GitHub Actions).
- Recommended IDEs: CLion.
- Code editors that support C++20 features.
- Use CMake for project configuration.
- Automate builds using CI/CD pipelines.
- Use Git for version control.
- Adopt a clear branching strategy for feature development.
- Target platforms: Windows, Linux, macOS.
- Provide deployment instructions and environment setup guides.
- Phase 1: Requirement Analysis & Detailed Design
- Phase 2: Core Module Development (Rendering, Physics, Audio, Input, GUI)
- Phase 3: Integration and Testing
- Phase 4: Optimization and Final Deployment
- Outline milestones with deadlines and deliverables.
- Vulkan: Cross-platfrom, multithreading, low-level with control over each step.
- Direct3D 12: Not cross-platform.
- Miniaudio: Minimal implementation, easy to abstract.
- Jolt: Powerfull, Modern and Efficient
- GLFW: Can work easily with Vulkan.
- Dear ImGui: Cross platform, multiple API compatibility layer.
- ImGuizmo: works with ImGui
- GLM: because their data structures are aligned with shaders.
- CMake: cross-platform and highly customizable.
| Element | Convention | Example |
|---|---|---|
| Namespace | Lowercase | gcep::render |
| Namespace prefix | gcep (Gaming Campus Engine Paris) |
gcep:: |
| Class name | PascalCase | RHI_Vulkan |
| Struct name | PascalCase | RenderData |
| Enum name | PascalCase | RenderBackend |
| Enum values | PascalCase | RenderBackend::Vulkan |
| Function name | camelCase, starts with a verb | createInstance() |
| Getter name | camelCase, starts with get |
getContext() |
| Variable name | camelCase | frameIndex |
| Member variable | m_ + camelCase |
m_context |
| Constant | UPPER_CASE | MAX_FRAMES_IN_FLIGHT |
| Macro | UPPER_CASE | DEBUG_MODE |
| File name | snake_case | rhi_vulkan.cpp |
| Header file | snake_case | rhi_vulkan.hpp |
| Indentation | 4 spaces | int value; |
| Braces style | Opening brace on new line | function()\n{} |
| Documentation | Doxygen | @brief Create instance |
| Attributes | [[nodiscard]] when applicable |
[[nodiscard]] int getId(); |
| Includes ordering | Internals / Externals / STL | see include rules |
| Include sorting | Alphabetical inside each group | <algorithm> before <vector> |
| Class access modifiers sorting | Public, Private, Protected | Inside : methods before members |
- Game Engine: The core framework managing all game processes.
- Module: A self-contained component providing specific functionality.
- Shader: A program executed on the GPU to control rendering.
- Include any additional architectural diagrams or flowcharts as needed.
- Additional resources on C++ game development and engine architecture.