meta: Always do GenerateMipmaps in linear colorspace.
authorKenneth Graunke <kenneth@whitecape.org>
Fri, 12 Aug 2016 21:48:54 +0000 (14:48 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 25 Aug 2016 18:07:01 +0000 (11:07 -0700)
commit6cf8708ce55fb38c400c8f005e55170f54241187
tree8379980873f3e5207c0bac7b98b276fb3a357712
parented871af91c2a34efde5073c91d87d1d31d50f5a8
meta: Always do GenerateMipmaps in linear colorspace.

When generating mipmaps for sRGB textures, force both decode and encode,
so the filtering is done in linear colorspace, regardless of settings.

Fixes a WebGL conformance test in Chrome:
https://www.khronos.org/registry/webgl/sdk/tests/conformance2/textures/misc/tex-srgb-mipmap.html?webglVersion=2

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97322
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
src/mesa/drivers/common/meta_generate_mipmap.c