Particle Life
17 months into coding | 9 Months into C++
Goals
Implementing a Particle Life model from scratch in C++ using SDL, 3 particle types governed by an attraction/repulsion logic, producing emergent collective behaviors from simple per-particle rules.
Focus on real-time performance with 1000+ simultaneous particles.
What's next ?
- Spatial Partitioning Find a better method to optimize the simulation.
- Runtime Rule Editing Use std::function for a better modularity.
- Better Patricle Path Particles shouldn't overlapse each others.
Each particle type defines force values toward every other type, borders and corners have been taken into account.
The simulation is being configured runtime using YAML files and yaml-cpp library.
1000+ particles updated and rendered each frame, with per-pair force calculation and velocity integration.
Sim Engine
13 months into coding | 5 Months into C++
Goals
Building a custom GUI framework and discrete event simulation engine from scratch using SDL3.
Focus on low-level performance and component reusability.
Notes for Future
- Wrappers Need for abstraction layers to handle dynamic UI scaling and window resizing.
-
Type Aliasing
usingdeclarations for variable types to keep the codebase readable. - Config Decoupling From header-based constants to external JSON/YAML configuration files.
- Better Design Patterns Observer for events, Factory for component instantiation.
Color palettes and font configs stored in external theme files, loaded at runtime via a theme manager.
Polymorphic component hierarchy: each UI element inherits from a base class (AUIElement), enabling consistent rendering and behavior across all components.
Menu trees defined recursively using a single file, nesting items creates routes automatically, no hardcoded layout required.
Physic Engine
9 months into coding | 1 Months into C++
Goals
Basic 2D rigid body environment focused on efficient collision detection and resolution. The core engine handles movement integration and geometric intersection tests.
This project was an introduction to C++.
Implementing spatial partitioning to maintain 60FPS even with high object density, moving beyond O(n²) complexity.
What's next?
- Impulse Resolution Adding momentum transfer and elastic kinetic energy exchange (bouncing).
- GJK Algorithm Moving from Circle-only logic to convex polygon collision detection.
- Celan Hardcoded Parts Create a system to have a better modularity.
Optimized "Screen Split" grid system that limits collision checks to local sectors, reducing CPU overhead.
Implemented using squared distance comparisons to avoid expensive square root operations during the detection phase.
Custom 'Shape' abstraction layer wrapping SFML primitives for decoupled logic and rendering.
Workflow usage example : Learning a new Langage
1 - Exercices resolution and note building, use of metadata
I asked my favourite LLM to generate me elementary exercice to solve in order to learn JS's basics.
I then create a note (markdown format) with the code snippet and metadata to arrange notes into topic.
2 - Image creation automation out of code snippet using python's html2image module
I made a python script to generate image using the snippet previously made, and use it as a cover to each note.
3 - Note integration using obsidian's dataview
I integrated the snippet notes into the subject's note in order to show example of usage.