blur: Downscale image before blurring
Unintuitively, combining the initial blur pass with downscaling makes
the rendering process slower because sampling from the high-resolution
image with bilinear sampling uses more memory bandwidth. It also
increases the total amount of ALU work because it effectively introduces
an unnecessary blur pass.
By downscaling the image with glBlitFramebuffer before running blur
passes, we can save a blur pass and render a more correct result. When
tested with 2 layers of another 6-pass blur implementation, this saves
~800 µs of rendering time on an Adreno 640 GPU at 1440x3040 resolution.
Change-Id: Ie897a52f1628e40d34c3c31f5f779020594bb091
Signed-off-by: Joey Huab <joey@evolution-x.org>
Signed-off-by: Ayan Mukherjee <mukherjeeayan725@gmail.com>
1 file changed