<html>
    <head>
      <base href="https://bugs.freedesktop.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Trine 2's fragment normal buffer is mixtextured on Radeon HD 6770 (Juniper)"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=66067#c7">Comment # 7</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Trine 2's fragment normal buffer is mixtextured on Radeon HD 6770 (Juniper)"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=66067">bug 66067</a>
              from <span class="vcard"><a class="email" href="mailto:greg@chown.ath.cx" title="Grigori Goronzy <greg@chown.ath.cx>"> <span class="fn">Grigori Goronzy</span></a>
</span></b>
        <pre>This actually seems to be a bug in Trine 2. The fragment shader uses a shadow
sampler to sample the normal texture, which is RGBA. This cannot work as shadow
sampling is only defined for depth textures. According to the
ARB_fragment_program_shadow specification (Trine 2 uses those old assembly-like
shaders for some reason), it is undefined behaviour to sample from non-depth
textures. Obviously, Trine 2 relies on a certain behavior, i.e. that shadow
samplers are silently changed into normal 2D samplers when not sampling from
depth textures.

I have contacted Frozenbyte support, let's see if they'll do something about.
Otherwise we need to check if it is reasonably possible and sensible to
implement these undefined cases like other drivers. This might get ugly,
though.

If you just want to play the game and don't mind hacking mesa, try the nasty
patch I attached. This will break other applications, but makes Trine 2 work.</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>