diff options
author | Brian Paul <[email protected]> | 2014-01-21 16:09:10 -0800 |
---|---|---|
committer | Brian Paul <[email protected]> | 2014-01-23 08:13:13 -0700 |
commit | b98fa6fe6ff10f0f210d44ea411c4ee7429ab2b3 (patch) | |
tree | 78630aa5bf5cded94bc0e6bb76eb4b8516d4a24e /src/mesa/main | |
parent | 91567b83bfd8979389f66635c50f36714a08a3f5 (diff) |
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 <[email protected]>
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/glformats.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c index bec7a9bbb6d..02709a17cf0 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: |