Project Page

CUDA Boids Simulation

GPU-accelerated flocking simulation with spatial partitioning.

C++CUDAOpenGL

Key Highlights

  • Real-time flocking simulation that scales to 100,000+ agents on a single GPU
  • Custom CUDA kernels paired with OpenGL instanced rendering for end-to-end frame-rate throughput
  • Optional spatial acceleration cuts neighbor search from quadratic to near-linear per frame

How It Scales

grid

  • One GPU thread per agent advances steering, integration, and boundary response in parallel, so update cost scales with hardware width instead of agent count
  • A uniform spatial grid bins agents by position so each one only checks the handful of cells in its neighborhood instead of the entire population

Why This Matters

  • Exercises the full pattern of a real-time GPU simulation: kernel design and the data flow between simulation and renderer at frame rate
  • Written from raw CUDA, C++, and OpenGL with no engine layer, showing comfort below frameworks