Boids 2D

This is a flocking agents simulation written in Unity with compute shaders as a project for the Arsiliath workshop. While some members of the workshop explored using texture-based solutions, myself and a few others explored more traditional sorting-based spatial partitioning solutions.

I built this project using Uniform Spatial Partitioning (as expertly explained in Chisolm) and learned how to implement a parallel prefix-sum operation for use in USP. The result was a simulation that could handle up to 5 million flocking agents in real time!

Key Highlights

  • 5 million agents interacting in complex ways in real time
  • Interactive simulation parameters allow for play
  • Customizable color gradients for more artistic expression
Copyright © '23 Jeff Schofield