Module: Mesa Branch: master Commit: b98fa6fe6ff10f0f210d44ea411c4ee7429ab2b3 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=b98fa6fe6ff10f0f210d44ea411c4ee7429ab2b3
Author: Brian Paul <bri...@vmware.com> Date: Tue Jan 21 16:09:10 2014 -0800 mesa: fix/add some cases in _mesa_get_linear_internalformat() In some cases we were converting generic formats to sized formats and vice versa. The point is to simply convert sRGB formats to corresponding linear formats. Reviewed-by: Marek Olšák <marek.ol...@amd.com> --- src/mesa/main/glformats.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c index bec7a9b..02709a1 100644 --- a/src/mesa/main/glformats.c +++ b/src/mesa/main/glformats.c @@ -1229,10 +1229,16 @@ _mesa_get_linear_internalformat(GLenum format) case GL_SRGB8_ALPHA8: return GL_RGBA8; - case GL_SLUMINANCE: + case GL_SLUMINANCE8: return GL_LUMINANCE8; + case GL_SLUMINANCE: + return GL_LUMINANCE; + case GL_SLUMINANCE_ALPHA: + return GL_LUMINANCE_ALPHA; + + case GL_SLUMINANCE8_ALPHA8: return GL_LUMINANCE8_ALPHA8; default: _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-commit