Created attachment 15441 [details] test case The attached test case enables POLYGON_OFFSET_LINE, and calls glPolygonOffset(0.0, 3000.0); When run with i915 and i965 driver, all of the edge pixels' depth value is 0. If run with soft rendering, the edge pixels' depth value is 0.045777.
I played with this a bit, and noted that making apply_offset do arbitrary changes to the vertex data had no effect, so we're probably writing to the wrong place or just not reaching that part of the loop.
depth offset is only applied to TRIANGLE object in WM state. The CLIP thread tries to do that for glPolygonMode(GL_LINE). Unfortunately it doesn't take effect.
The issue on 965 is fixed in mesa 184cf464f4183a664fa0358fe118735e6fd98afe.
I don't see this issue on 915
Still has one edge is incorrect, Reopen this bug. with 965 and 915 driver, the output is: [root@x-g965 mycase]# ./fpmisc_15194 get depth values: 0.000000 0.045777 0.045777 0.045777 [root@x-945gm mycase]# ./fpmisc_15194 get depth values: 0.000000 0.000358 0.000358 0.000358 With soft rendering, the output is: [root@x-945gm mycase]# $SW ./fpmisc_15194 get depth values: 0.045777 0.045777 0.045777 0.045777
(In reply to comment #5) > Still has one edge is incorrect, Reopen this bug. > > with 965 and 915 driver, the output is: > [root@x-g965 mycase]# ./fpmisc_15194 > get depth values: 0.000000 0.045777 0.045777 0.045777 > > [root@x-945gm mycase]# ./fpmisc_15194 > get depth values: 0.000000 0.000358 0.000358 0.000358 > > With soft rendering, the output is: > [root@x-945gm mycase]# $SW ./fpmisc_15194 > get depth values: 0.045777 0.045777 0.045777 0.045777 > This is a new problem. In fact, if draw a polygon without depth offset, and set the depth value to 0.5, you will also get 0.00, 0.5, 0.5, 0.5. It seems there is one pixel bias. glReadPixels(24, 50, 1, 1, GL_DEPTH_COMPONENT, GL_FLOAT, &buf[0]) can get the depth values. Please open a new bug to track this new issue and I close this bug.
Open bug #15444. Close this one.
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.