<html>
    <head>
      <base href="https://bugs.freedesktop.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [IVB] LINE_STRIPs following a TRIANGLE_FAN fail to use primitive restart"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=109451">109451</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[IVB] LINE_STRIPs following a TRIANGLE_FAN fail to use primitive restart
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>Mesa
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>18.3
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>x86-64 (AMD64)
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux (All)
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Drivers/DRI/i965
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>intel-3d-bugs@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>perso@elementw.net
          </td>
        </tr>

        <tr>
          <th>QA Contact</th>
          <td>intel-3d-bugs@lists.freedesktop.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=143227" name="attach_143227" title="apitrace of example program">attachment 143227</a> <a href="attachment.cgi?id=143227&action=edit" title="apitrace of example program">[details]</a></span>
apitrace of example program

Originally reported as a Blender bug: <a href="https://developer.blender.org/T60762">https://developer.blender.org/T60762</a>
(which it is not)

Using desktop GL 3.3+.

Steps to reproduce:
* prepare a vertex and index buffer
* enable GL_PRIMITIVE_RESTART
* draw a GL_TRIANGLE_FAN using those buffers
* draw any number of GL_LINE_STRIPs with those same buffers

Drawing a GL_TRIANGLE_FAN prior to GL_LINE_STRIPs makes the strip draw calls
fail to use restart markers (here, 0xFF), resulting in the line strips'
supposedly unconnected strips being connected through a point of invalid
coordinates (observed to consistently be (0, 0, 0)).
IOW, restart markers seems to be (re-)considered as normal indices.

Interfering with GL calls that read or write to the index buffer makes the
problem go away, hinting at a GL state tracking or cache issue.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the QA Contact for the bug.</li>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>