The flocking algorithm mimics behaviors commonly seen in nature. A typical example of this behavior is the flight of birds in a flock. This repo contains C++ implementation both for CPU and GPU using compute shaders. Implementation includes:
- CPU naive
- CPU octree-based
- GPU brute-force
- GPU regular grid
I made a blogpost describing the design, there are also some outputs, see more here!