OpenGL ES SDK for Android
ARM Developer Center
|
This document describes how to enable and use the ASTC decode mode extension to select decoding precision when decoding ASTC image blocks.
This tutorial shows how the EXT_texture_compression_astc_decode_mode extension can be used to enable different levels of decoding precision. For more information about how ASTC is used, please see ASTC textures.
The existing specifications require that low dynamic range (LDR) textures are decompressed to FP16 values per component. In many cases, decompressing LDR textures to a lower precision intermediate result gives acceptable image quality. Source material for LDR textures is typically authored as 8-bit UNORM values, so decoding to FP16 values adds little value. On the other hand, reducing precision of the decoded result reduces the size of the decompressed data, potentially improving texture cache performance and saving power.
The goal of this extension is to enable this efficiency gain on existing ASTC texture data. This is achieved by giving the application the ability to select the decoding precision.
Two decoding options are provided by GL_EXT_texture_compression_astc_decode_mode
If GL_EXT_texture_compression_astc_decode_mode_rgb9e5 is supported, then a third decoding option is provided:
Decode mode is set using the a texture parameter set using the glTexParameter* functions.
Supported decode modes:
[1] https://www.khronos.org/registry/gles/extensions/KHR/texture_compression_astc_hdr.txt
[2] https://www.khronos.org/registry/OpenGL/extensions/EXT/EXT_texture_compression_astc_decode_mode.txt
[3] http://malideveloper.arm.com/develop-for-mali/tools/astc-evaluation-codec/