summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIlia Mirkin <imirkin@alum.mit.edu>2016-03-11 21:26:31 -0500
committerEmil Velikov <emil.l.velikov@gmail.com>2016-03-29 11:29:05 +0100
commitaa422705dc94fa702820bb1f33906ced91c3c2ed (patch)
tree4353f9238c8a36df1e53695e62aff19d9ab41d2b
parentf755b71f45d6ecf7e349c1712098a593eec68a9c (diff)
nvc0: fix blit triangle size to fully cover FB's > 8192x8192
The idea is that a single triangle will cover the whole area being drawn, allowing the blit shader to do its work. However the max fb size is 16384x16384, which means that the triangle we draw needs to be twice that in order to cover the whole area fully. Increase the size of the triangle to 32768x32768. This fixes a number of dEQP tests that were failing because a blit was involved which would miss some of the resulting texture. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Cc: "11.1 11.2" <mesa-stable@lists.freedesktop.org> (cherry picked from commit a651bc027d5ed4150bb5240fc9f46a6ca569f665)
-rw-r--r--src/gallium/drivers/nouveau/nvc0/nvc0_surface.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_surface.c b/src/gallium/drivers/nouveau/nvc0/nvc0_surface.c
index 6f6d46c2991..f4234b3367a 100644
--- a/src/gallium/drivers/nouveau/nvc0/nvc0_surface.c
+++ b/src/gallium/drivers/nouveau/nvc0/nvc0_surface.c
@@ -1203,8 +1203,8 @@ nvc0_blit_3d(struct nvc0_context *nvc0, const struct pipe_blit_info *info)
x0 = (float)info->src.box.x - x_range * (float)info->dst.box.x;
y0 = (float)info->src.box.y - y_range * (float)info->dst.box.y;
- x1 = x0 + 16384.0f * x_range;
- y1 = y0 + 16384.0f * y_range;
+ x1 = x0 + 32768.0f * x_range;
+ y1 = y0 + 32768.0f * y_range;
x0 *= (float)(1 << nv50_miptree(src)->ms_x);
x1 *= (float)(1 << nv50_miptree(src)->ms_x);
@@ -1314,14 +1314,14 @@ nvc0_blit_3d(struct nvc0_context *nvc0, const struct pipe_blit_info *info)
*(vbuf++) = fui(y0);
*(vbuf++) = fui(z);
- *(vbuf++) = fui(16384 << nv50_miptree(dst)->ms_x);
+ *(vbuf++) = fui(32768 << nv50_miptree(dst)->ms_x);
*(vbuf++) = fui(0.0f);
*(vbuf++) = fui(x1);
*(vbuf++) = fui(y0);
*(vbuf++) = fui(z);
*(vbuf++) = fui(0.0f);
- *(vbuf++) = fui(16384 << nv50_miptree(dst)->ms_y);
+ *(vbuf++) = fui(32768 << nv50_miptree(dst)->ms_y);
*(vbuf++) = fui(x0);
*(vbuf++) = fui(y1);
*(vbuf++) = fui(z);