The Axiom Journey: Engineering a High-Performance Engine
Inside the Axiom Engine
Building Axiom was more than just a coding exercise; it was a journey into the deepest layers of computer graphics and performance optimization. When I first started, my goal was simple: render 10,000 active entities at 60 FPS.
The Bottleneck: Draw Calls
In my initial builds, performance tanked after just 500 entities. The CPU was spending 99% of its time telling the GPU "draw this sprite" thousands of times. This led me to my first major breakthrough: Sprite Batching.
By consolidating thousands of sprites into a single vertex data buffer (VBO) and issuing just one draw call per frame, I achieved a jump from 30 FPS to 166+ FPS with over 10,000 entities.
Core Architecture
Axiom is built on three main pillars:
- Custom ECS: A powerful Entity-Component System that decouples data from logic, allowing for highly efficient memory access and parallel processing.
- Hardware-Accelerated Rendering: Direct OpenGL communication with custom GLSL shaders.
- Fixed-Time Step Loop: Ensuring consistent gameplay physics regardless of the user's frame rate.
Looking Ahead
The Axiom journey is far from over. Future iterations will focus on spatial partitioning for collision optimization and a more robust scripting layer for logic.