Implement compute-shader simulation of particles!
This uses a workaround for the previously mentioned shader glitch in
order to use the compute shaders successfully. Bjorn notes that reading
from an SSBO makes rendering start working properly. In order to
*hopefully* make this cheaper, I add a variable to the buffer that's
intended for only reading like this, which ends up being sufficient to
fix the behavior of the whole buffer.
The discussion comment with the workaround:
https://github.com/bjornbytes/lovr/issues/211#issuecomment-
580985010
> Reading data out of the buffer (print(block:read('value')[1])) after
> the compute also fixes it, I suspect maybe because it maps the buffer.
For simulation, this updates the positions with the velocity, and
applies uniform quadratic drag to the particles.