[Bug 95530] Stellaris - colored overlay of sectors doesn't render on i965

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Jun 8 08:54:19 UTC 2017


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

--- Comment #11 from Jakub Szuppe <jakub+mesa at streamcomputing.eu> ---
Sectors have "noisy" borders and very low transparency on i965 driver (Mesa
17.1.0-devel (git-d5ee55f)). Other Mesa drivers (llvmpipe and radeonsi) work
correctly.

How it looks like on i965:
https://drive.google.com/open?id=0B1fY17pW39ZeWUoxVXJWUU42dFk

How it should:
https://drive.google.com/open?id=0B1fY17pW39ZeUGhQdmRTUS1UVWc

These overlays are rendered using render-to-texture in the call 2149486:
https://drive.google.com/open?id=0B1fY17pW39ZedlFDREwwSFB6Nzg

The program 706 (a fragment shader 708, created in 911931) uses two textures
with

glTexParameteri(target = GL_TEXTURE_2D, pname = GL_TEXTURE_MIN_FILTER, param =
GL_NEAREST)
glTexParameteri(target = GL_TEXTURE_2D, pname = GL_TEXTURE_MAG_FILTER, param =
GL_NEAREST)

These textures also have GL_TEXTURE_MAX_ANISOTROPY_EXT set to 16:

glTexParameterf(target = GL_TEXTURE_2D, pname = GL_TEXTURE_MAX_ANISOTROPY_EXT,
param = 16)

Setting GL_TEXTURE_MAX_ANISOTROPY_EXT to 1 for both textures fixes the issue:
https://drive.google.com/open?id=0B1fY17pW39Zec2pMa3dIN0Nobjg

I.e., GL_TEXTURE_MAX_ANISOTROPY_EXT disables GL_NEAREST, and because the shader
highly depends on exact texel values (it calculates sums, maximum of values of
the first texture, uses the second texture as a look-up table), the results
have such a big difference.

Here the code that disables GL_NEAREST in this case:
https://cgit.freedesktop.org/mesa/mesa/tree/src/mesa/drivers/dri/i965/brw_sampler_state.c#n454

We've found one issue with a proposed patch here:
https://bugs.freedesktop.org/show_bug.cgi?id=91786

The patched driver produces correct results for both traces.

Kind regards,
Stream HPC Team
https://streamhpc.com/

-- 
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/20170608/c23aa288/attachment.html>


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