Compute Shaders! The last type. The last big lego to take out of the box There are more little ones The abstract compute space 3D grid of workgroups A workgroup is like what we have with vertex shaders, etc So you can have multiple instances in a workgroup But, the instances are a 3D grid So you have a 3D grid of instances within a 3D grid of workgroups A lot of the time, you can ignore one 3D grid or the other Or even 2 out of 3 dimensions Storage! Shader Storage Buffers It's the in out parameter we've been wanting... Interesting question: Can we use one from a vertex shader? Declared as a "buffer", but we have to explain the layout Layout specification: packed, shared, std140, std430 Favors alignment on 4 float (128 bit) lines - I couldn't dissuade my drivers from doing this binding number Inputs: stuff about abstract compute space Outputs: Nothing predefined Names: layout( ) buffer { members } ; Input/Output is mostly just up to you! Example: Using compute shaders to move the cube around Getting data out of a buffer, in case you need it for something Like last week's feedback example So now we could actually use these for general purpose computation Or physics... Practice Problem: Add velocity to the x or z direction for the cube vertices. Try making them the same, and different!