
This is a port of the film grain shader from https://www.shadertoy.com/view/Mdj3zd but combined with the concept of a pixelated screen shader from https://gamedev.stackexchange.com/quest ... ion-shader
What makes this shader different from your typical film grain shader? Have you noticed that with usual film grain shaders, the effect becomes harder to see as your video resolution goes up? That is because the effect is applied per-pixel, so at 640x480, for example, the effect is very clear, but at 4k resolution, you almost can't see the effect because the pixels are too tiny. Then you compensate for this by cranking the "amount", but then it starts to look bad because you are just making the viewport harder to see.
With this shader, the size of one "grain" stays constant no matter resolution you're using. You can use the options to adjust the pixel size - lower number produces larger, blockier grains.
This shader is best understood by just running it and playing with the options, while changing resolutions. The film grain effect and intensity will remain consistent regardless of whatever resolution you set.
Have fun!
EDIT: Updated on 02/28/2020 - better random noise generator (fixes weird bug where the grain starts having zig-zag patterns after extended lengths of time)