Bug 2010 - depth and stencil readback are broken beyond x > 1023
Summary: depth and stencil readback are broken beyond x > 1023
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/r200 (show other bugs)
Version: git
Hardware: x86 (IA32) Linux (All)
: high normal
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-12-03 19:00 UTC by Roland Scheidegger
Modified: 2009-08-24 12:22 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Roland Scheidegger 2004-12-03 19:00:53 UTC
depth and stencil readback are broken on r200 based cards beyond x coordinate
1023 (and I believe y coordinate too but not tested) (Mesa tests zreaddraw,
stencilwrap, move them to out of the right border on a 1280x1024 desktop and
back in to get a redraw). This appears to be caused by the r200_mba_z16 and
r200_mga_z32 functions in r200_span.c which use masks (y & 0x3FF) and (x &
0x3FF) respectively which will limit addressing to coordinates lower than 1024.
I'm not sure what the correct fix would be, though using 0x7FF (2047 which is
the 3d hardware limit for a single cliprect) solves the issue. But since this
just calculates a memory address, why is a mask even needed?
Comment 1 Roland Scheidegger 2004-12-07 19:10:00 UTC
fixed in cvs (with new limit 2047 instead of 1023, since I don't quite
understand if there could be issues if it's increased beyond limits, and 2047 is
the current limit for 3d rendering anyway).
Comment 2 Roland Mainz 2004-12-07 19:28:53 UTC
Roland Scheidegger wrote:
> and 2047 is
> the current limit for 3d rendering anyway).

Where does this limit come from ? Is that just one of the MESA-specific
"artificial clamps" or something else ?
Comment 3 Keith Whitwell 2004-12-08 03:49:32 UTC
The 2047 limit is iirc the maximum size you can specify for a radeon cliprect,
maybe other hardware limitations as well.

The "artificial" mesa limits aren't artificial at all but are the result of
limitations in interpolating values across large triangles in the software
rasterizer.
Comment 4 Adam Jackson 2009-08-24 12:22:54 UTC
Mass version move, cvs -> git


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.