aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main/texformat.c
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mesa/main/texformat.c')
-rw-r--r--mesalib/src/mesa/main/texformat.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/mesalib/src/mesa/main/texformat.c b/mesalib/src/mesa/main/texformat.c
index 6d8e272ba..c776b4160 100644
--- a/mesalib/src/mesa/main/texformat.c
+++ b/mesalib/src/mesa/main/texformat.c
@@ -763,12 +763,12 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat,
case GL_RG:
case GL_RG8:
- RETURN_IF_SUPPORTED(MESA_FORMAT_RG88);
+ RETURN_IF_SUPPORTED(MESA_FORMAT_GR88);
break;
case GL_COMPRESSED_RG:
RETURN_IF_SUPPORTED(MESA_FORMAT_RG_RGTC2);
- RETURN_IF_SUPPORTED(MESA_FORMAT_RG88);
+ RETURN_IF_SUPPORTED(MESA_FORMAT_GR88);
break;
case GL_RG16:
@@ -919,6 +919,16 @@ _mesa_choose_tex_format( struct gl_context *ctx, GLint internalFormat,
}
}
+ if (ctx->Extensions.OES_compressed_ETC1_RGB8_texture) {
+ switch (internalFormat) {
+ case GL_ETC1_RGB8_OES:
+ RETURN_IF_SUPPORTED(MESA_FORMAT_ETC1_RGB8);
+ break;
+ default:
+ ; /* fallthrough */
+ }
+ }
+
_mesa_problem(ctx, "unexpected format %s in _mesa_choose_tex_format()",
_mesa_lookup_enum_by_nr(internalFormat));
return MESA_FORMAT_NONE;