mesa/formats: Take luminance into account in component count
authorTopi Pohjolainen <topi.pohjolainen@intel.com>
Fri, 22 Apr 2016 08:07:06 +0000 (11:07 +0300)
committerTopi Pohjolainen <topi.pohjolainen@intel.com>
Sat, 23 Apr 2016 04:29:15 +0000 (07:29 +0300)
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
src/mesa/main/glformats.c

index 96ab393c0e1ac63b48541797117ed0944ee5b05a..9274dc017753c14231ed5ebc6682cef468e31dff 100644 (file)
@@ -1569,6 +1569,7 @@ GLint
 _mesa_base_format_component_count(GLenum base_format)
 {
    switch (base_format) {
+   case GL_LUMINANCE:
    case GL_RED:
    case GL_ALPHA:
    case GL_INTENSITY: