You blur a pixel by mixing in colours from the surrounding pixels. Like smearing paints to blur a painting.
The process of rendering is going object by object through the virtual world and transforming its 3d information into pixels. This happens in parallel for thousands pixels at a time. There is no set order. For this reason the code that calculates the colour of a pixel does not know the colour of its neighbouring pixels.
Even if it could know, what would this mean for blurring? I need the unblurred colour from the neighbouring pixel. If my program is producing blurred colours then I’m stuck. My neighbouring pixel is already blurred. I need all the unblurred colours for a blur effect.
For this reason blurring is done by rendering to an image and then blurring the result, an expensive extra step.
This texture is a normal rectangle texture of a certain resolution, so there is no way to have less resolution in the area I know I’m going to blur.
There is a variable rate shader (the program that runs on your GPU) that calculates a single colour that is used by multiple pixels. So that is one solution that may help here, I’m bit out of touch to know if this is common. It was a big promise for VR and eye tracking so that you could render more details where the eye is looking.
Latest Answers