meta: Fix blitting a framebuffer with renderbuffer attachment
authorAnuj Phogat <anuj.phogat@gmail.com>
Mon, 5 Aug 2013 21:27:47 +0000 (14:27 -0700)
committerAnuj Phogat <anuj.phogat@gmail.com>
Fri, 16 Aug 2013 16:46:15 +0000 (09:46 -0700)
commitd944a6144f6ee6a0b24126ce72de280db90038c9
tree63d09da7ca7ebeb0b26d81a1bc0112fa08e7db06
parenta2061eea0f89b44c816e6c7570b983e8cfda41cd
meta: Fix blitting a framebuffer with renderbuffer attachment

This patch fixes a case of framebuffer blitting with renderbuffer
as color attachment and GL_LINEAR filter. Meta implementation of
glBlitFrambuffer() converts source color buffer to a texture and
uses it to do the scaled blitting in to destination buffer. Using
the exact source rectangle to create the texture does incorrect
linear filtering along the edges. This patch makes the changes to
extend the texture edges by one pixel in x, y directions. This
ensures correct linear filtering.
It fixes failing piglit fbo-attachments-blit-scaled-linear test.

Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
CC: "9.2" <mesa-stable@lists.freedesktop.org>
CC: "9.1" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Paul Berry <stereotype441@gmail.com>
src/mesa/drivers/common/meta.c