[Mesa-dev] [Bug 41787] [llvmpipe] stencil broken

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Mon Oct 17 16:56:13 PDT 2011


https://bugs.freedesktop.org/show_bug.cgi?id=41787

--- Comment #10 from Brian Paul <brianp at vmware.com> 2011-10-17 16:56:13 PDT ---
Created attachment 52451
  --> https://bugs.freedesktop.org/attachment.cgi?id=52451
glut test program

Jose, I extracted some of the commands from the trace into a glut test harness
and I think I've reproduced the bug.

A yellow floor quad is drawn first.  Then a sphere is drawn (as a stand-in for
a shadow volume) into the stencil buffer then the shadow itself is drawn by
drawing a window-sized quad with blending and stencil test.

If you look carefully, there's stray red pixels just below the round shadow. 
If you rotate the scene (cursor keys, z, Z) you'll see the stray pixels
randomly move around.

If you decrease the sphere tessellation, the number of artifacts decreases.  In
the previously attached trace, the shadow volume appears to be very complicated
(23424 vertices).  If you make the window smaller, the number of artifacts is
less than if the window is large.

It seems as if we're writing stray pixels in the stencil code when drawing very
small triangles.  But only when polygon culling is enabled.

Adding an initial glClear(GL_STENCIL_BUFFER_BIT) doesn't make any difference.

If I have time this week I'll try to debug further.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the mesa-dev mailing list