summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnuj Phogat <anuj.phogat@gmail.com>2012-02-13 10:48:45 -0800
committerIan Romanick <ian.d.romanick@intel.com>2012-02-15 14:48:59 -0800
commitd45a5fde45e30c4475a92217b582c73d8ef5f52b (patch)
tree6b5d7d2b9eaeab964f538b08ee2e7c55ca2c2038
parente55f2d97f61420f6004c60be4238799f7a35b440 (diff)
meta: Avoid FBO resizing/reallocating in decompress_texture_image
Reallocate/resize decompress FBO only if texture image width/height is greater than existing decompress FBO width/height. This is a candidate for stable branches. Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit 66bf25f1a2cc8343640cdfc4242d882bc00b9e3b)
-rw-r--r--src/mesa/drivers/common/meta.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/common/meta.c b/src/mesa/drivers/common/meta.c
index 2b994de565f..4dd9b29d5a6 100644
--- a/src/mesa/drivers/common/meta.c
+++ b/src/mesa/drivers/common/meta.c
@@ -3291,7 +3291,7 @@ decompress_texture_image(struct gl_context *ctx,
}
/* alloc dest surface */
- if (width != decompress->Width || height != decompress->Height) {
+ if (width > decompress->Width || height > decompress->Height) {
_mesa_RenderbufferStorageEXT(GL_RENDERBUFFER_EXT, GL_RGBA,
width, height);
decompress->Width = width;