[Bug 102678] gl_BaseVertex should always be zero when the draw command has no <basevertex> parameter

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Oct 12 18:34:30 UTC 2017


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

Antia Puentes <apuentes at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |apuentes at igalia.com,
                   |                            |idr at freedesktop.org,
                   |                            |kenneth at whitecape.org

--- Comment #3 from Antia Puentes <apuentes at igalia.com> ---
(In reply to Antia Puentes from comment #2)
> (In reply to Kenneth Graunke from comment #1)
> > I believe Antia is working on a fix.
> 
> I have a patch that fixes the tests. I am currently testing for regressions,
> if there isn't any I will send it shortly.

The patch produced regressions related to gl_VertexID. Specifically in the
tests which involve gl*DrawArrays*, pass a value different from zero as
argument of the <first> parameter of the draw command, and check if gl_VertexID
is correct.

According to the spec, for non-indexed draw calls: "The vertex ID of the ith
element transferred is <first> + i."

Mesa's compiler lowers the gl_VertexID as gl_VertexID(base zero) +
gl_BaseVertex, which is the way expected for indexed draw calls. For
non-indexed draw calls, this currently works because we use the <first>
argument as gl_BaseVertex. If we give gl_BaseVertex a zero value for
gl*DrawArrays* as the spec says, the gl_VertexID will be incorrect.

Not sure how to fix the gl_VertexID issue, it looks like the i965 does not have
a way to add a base value during the vertex-id generation.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/intel-3d-bugs/attachments/20171012/72cf940f/attachment.html>


More information about the intel-3d-bugs mailing list