summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorRoland Scheidegger <rscheidegger@gmx.ch>2004-12-08 03:07:34 +0000
committerRoland Scheidegger <rscheidegger@gmx.ch>2004-12-08 03:07:34 +0000
commite1b4fec71c1a22ea7415a115700802a93b52fcc7 (patch)
tree3586b831f454e01045c2d8c8735946934bf37e08 /src/mesa
parent3b65cab455fb74156258af063aa1278124c65788 (diff)
fix depth/stencil readback if coordinates are larger than 1023 (https://bugs.freedesktop.org/show_bug.cgi?id=2010). Should now work up to 2047, which is the current limit for 3d rendering.
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/r200/r200_span.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/r200/r200_span.c b/src/mesa/drivers/dri/r200/r200_span.c
index efb5e6ea7c..3747948984 100644
--- a/src/mesa/drivers/dri/r200/r200_span.c
+++ b/src/mesa/drivers/dri/r200/r200_span.c
@@ -161,7 +161,7 @@ static GLuint r200_mba_z32( r200ContextPtr rmesa,
GLint x, GLint y )
{
GLuint pitch = rmesa->r200Screen->frontPitch;
- GLuint b = ((y & 0x3FF) >> 4) * ((pitch & 0xFFF) >> 5) + ((x & 0x3FF) >> 5);
+ GLuint b = ((y & 0x7FF) >> 4) * ((pitch & 0xFFF) >> 5) + ((x & 0x7FF) >> 5);
GLuint a =
(BIT(x,0) << 2) |
(BIT(y,0) << 3) |
@@ -180,7 +180,7 @@ static GLuint r200_mba_z32( r200ContextPtr rmesa,
static GLuint r200_mba_z16( r200ContextPtr rmesa, GLint x, GLint y )
{
GLuint pitch = rmesa->r200Screen->frontPitch;
- GLuint b = ((y & 0x3FF) >> 4) * ((pitch & 0xFFF) >> 6) + ((x & 0x3FF) >> 6);
+ GLuint b = ((y & 0x7FF) >> 4) * ((pitch & 0xFFF) >> 6) + ((x & 0x7FF) >> 6);
GLuint a =
(BIT(x,0) << 1) |
(BIT(y,0) << 2) |