[Mesa-dev] [V2 16/19] mesa: Handle astc 3d formats in _mesa_base_tex_format()

Anuj Phogat anuj.phogat at gmail.com
Mon Mar 21 21:04:10 UTC 2016


Signed-off-by: Anuj Phogat <anuj.phogat at gmail.com>
---
 src/mesa/main/glformats.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c
index 7245f66..fa064e5 100644
--- a/src/mesa/main/glformats.c
+++ b/src/mesa/main/glformats.c
@@ -2387,8 +2387,10 @@ _mesa_base_tex_format(const struct gl_context *ctx, GLint internalFormat)
             return base_compressed;
    }
 
-   if (ctx->Extensions.KHR_texture_compression_astc_ldr &&
-      _mesa_is_astc_format(internalFormat))
+   if ((ctx->Extensions.KHR_texture_compression_astc_ldr &&
+        is_astc_2d_format(internalFormat)) ||
+       (ctx->Extensions.OES_texture_compression_astc &&
+        is_astc_3d_format(internalFormat)))
         return GL_RGBA;
 
    if (ctx->Extensions.MESA_ycbcr_texture) {
-- 
2.5.0



More information about the mesa-dev mailing list