[Mesa-dev] [PATCH V3 00/13] intel: Add ETC2 compressed texture support

Anuj Phogat anuj.phogat at gmail.com
Mon Nov 12 19:48:44 PST 2012


This series lives on my gles3-etc2-v3 branch (https://github.com/aphogat/mesa).

It enables ETC2 texture formats for all Intel hardware. ETC2 texture
data is decoded into a suitable uncompressed mesa format at the time
of glCompressedTexImage2D. These patches can be tested using piglit
test case i have posted for etc2 textures. Patches for the test are
under review on piglit mailing list.

Changes in V2:
 - Now decodes SRGB ETC2 formats to MESA_FORMAT_SARGB.
 - Fixed an issue with signed-{r, rg}11 decoding. Decoded 16 bit signed
   data is now converted to 16 bit unsigned data by adding 2 ^ 15 and
   stored in an unsigned mesa texture format. This makes piglit etc2
   test case pass for these formats.
 - Added entries to texfetch_funcs[] array. ETC2 piglit test passes on
   swrast.
 - Squashed together all patches to enable etc2 formats on intel h/w.
 - Now uses nonlinear_to_linear() function to convert from SRGB to
   linear RGB.

Changes in V3:
 - Squash all "mesa: Add new ETC2 format" patches together.
 - nonlinear_to_linear() function is made non static inline.
 - Correctly increment variable 'n' in _mesa_get_compressed_formats.
 - Remove unnecessary casts in _mesa_fetch_texel_* functions in
   texcompress_etc.c.
 - Use uint8_t uniformly across texcompress_etc.c.
 - Fix indentation issues.

Anuj Phogat (13):
  mesa: Add new MESA_FORMATs for ETC2 compressed textures
  mesa: Make nonlinear_to_linear() function available outside file
  mesa: Add decoding functions for GL_COMPRESSED_RGB8_ETC2
  mesa: Add decoding functions for GL_COMPRESSED_SRGB8_ETC2
  mesa: Add decoding functions for GL_COMPRESSED_RGBA8_ETC2_EAC
  mesa: Add decoding functions for GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC
  mesa: Add decoding functions for GL_COMPRESSED_R11_EAC
  mesa: Add decoding functions for GL_COMPRESSED_RG11_EAC
  mesa: Add decoding functions for GL_COMPRESSED_SIGNED_R11_EAC
  mesa: Add decoding functions for GL_COMPRESSED_SIGNED_RG11_EAC
  mesa: Add decoding functions for
    GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2
  mesa: Add decoding functions for
    GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2
  intel: Enable ETC2 support on intel hardware

 src/mesa/drivers/dri/i965/brw_wm_surface_state.c |   14 +
 src/mesa/drivers/dri/intel/intel_mipmap_tree.c   |   94 ++-
 src/mesa/drivers/dri/intel/intel_mipmap_tree.h   |   25 +-
 src/mesa/main/format_unpack.c                    |   77 ++-
 src/mesa/main/format_unpack.h                    |    3 +
 src/mesa/main/formats.c                          |  133 +++
 src/mesa/main/formats.h                          |   10 +
 src/mesa/main/glformats.c                        |   21 +
 src/mesa/main/texcompress.c                      |  100 ++
 src/mesa/main/texcompress_etc.c                  | 1373 +++++++++++++++++++++-
 src/mesa/main/texcompress_etc.h                  |   79 ++-
 src/mesa/main/texcompress_s3tc.c                 |   28 +-
 src/mesa/main/texformat.c                        |   37 +
 src/mesa/main/teximage.c                         |   21 +
 src/mesa/main/texstore.c                         |   12 +
 src/mesa/swrast/s_texfetch.c                     |   60 +
 16 files changed, 2038 insertions(+), 49 deletions(-)

-- 
1.7.7.6



More information about the mesa-dev mailing list