<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 - Shader replacements works only for limited use cases"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=106283">106283</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Shader replacements works only for limited use cases
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

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

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>glsl-compiler
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>mesa-dev@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>iive@yahoo.com
          </td>
        </tr>

        <tr>
          <th>QA Contact</th>
          <td>intel-3d-bugs@lists.freedesktop.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>In the mesa documentation here: <a href="https://www.mesa3d.org/shading.html#envvars">https://www.mesa3d.org/shading.html#envvars</a>
you can find a section about "Shader Replacement" that tells you how you can
dump the source of GLSL shaders and even replace some shaders with your own.

Unfortunately, I couldn't make this work for the app that is having a problem.

I dig a bit in the Mesa code and came to the conclusion that the dump&replace
works only for the  glProgramStringARB(),  while the app seems to provide the
shader through  glShaderSourceARB()  that seems to be completely separate from
the code that supports dump&replace.

It would be nice if this feature could work with all code paths.

In the past, I've been able to narrow down at least two R600 assembly bugs, by
tweaking the shaders that generate them (using d3d9 library that can do that).
It's very disappointing that Mesa has the functionality, but it works only for
a limited code paths.

At very least, document properly that quirk.</pre>
        </div>
      </p>


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

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