15bd8deadSopenharmony_ciName 25bd8deadSopenharmony_ci 35bd8deadSopenharmony_ci AMD_compressed_ATC_texture 45bd8deadSopenharmony_ci 55bd8deadSopenharmony_ciName Strings 65bd8deadSopenharmony_ci 75bd8deadSopenharmony_ci GL_AMD_compressed_ATC_texture 85bd8deadSopenharmony_ci 95bd8deadSopenharmony_ciContributors 105bd8deadSopenharmony_ci 115bd8deadSopenharmony_ci Aaftab Munshi 125bd8deadSopenharmony_ci Benj Lipchak 135bd8deadSopenharmony_ci 145bd8deadSopenharmony_ciContact 155bd8deadSopenharmony_ci 165bd8deadSopenharmony_ci Maurice Ribble, Qualcomm (mribble 'at' qualcomm.com) 175bd8deadSopenharmony_ci 185bd8deadSopenharmony_ciIP Status 195bd8deadSopenharmony_ci 205bd8deadSopenharmony_ci Please contact AMD regarding any intellectual property questions/issues 215bd8deadSopenharmony_ci associated with this extension. 225bd8deadSopenharmony_ci 235bd8deadSopenharmony_ciStatus 245bd8deadSopenharmony_ci 255bd8deadSopenharmony_ci Complete. 265bd8deadSopenharmony_ci 275bd8deadSopenharmony_ciVersion 285bd8deadSopenharmony_ci 295bd8deadSopenharmony_ci Last Modified Date: February 26, 2008 305bd8deadSopenharmony_ci Revision: 7 315bd8deadSopenharmony_ci 325bd8deadSopenharmony_ciNumber 335bd8deadSopenharmony_ci 345bd8deadSopenharmony_ci OpenGL ES Extension #40 355bd8deadSopenharmony_ci 365bd8deadSopenharmony_ciDependencies 375bd8deadSopenharmony_ci 385bd8deadSopenharmony_ci Written based on the wording of the OpenGL ES 1.1 specification. 395bd8deadSopenharmony_ci 405bd8deadSopenharmony_ciOverview 415bd8deadSopenharmony_ci 425bd8deadSopenharmony_ci This extension enables support for ATC compressed texture formats. ATC is 435bd8deadSopenharmony_ci AMD's proprietary compression algorithm for compressing textures for 445bd8deadSopenharmony_ci handheld devices to save on power consumption, memory footprint and 455bd8deadSopenharmony_ci bandwidth. 465bd8deadSopenharmony_ci 475bd8deadSopenharmony_ci Three compression formats are introduced: 485bd8deadSopenharmony_ci 495bd8deadSopenharmony_ci - A compression format for RGB textures. 505bd8deadSopenharmony_ci - A compression format for RGBA textures using explicit alpha encoding. 515bd8deadSopenharmony_ci - A compression format for RGBA textures using interpolated alpha encoding. 525bd8deadSopenharmony_ci 535bd8deadSopenharmony_ciNew Procedures and Functions 545bd8deadSopenharmony_ci 555bd8deadSopenharmony_ci None. 565bd8deadSopenharmony_ci 575bd8deadSopenharmony_ciNew Tokens 585bd8deadSopenharmony_ci 595bd8deadSopenharmony_ci Accepted by the <internalformat> parameter of CompressedTexImage2D and 605bd8deadSopenharmony_ci CompressedTexImage3DOES. 615bd8deadSopenharmony_ci 625bd8deadSopenharmony_ci ATC_RGB_AMD 0x8C92 635bd8deadSopenharmony_ci ATC_RGBA_EXPLICIT_ALPHA_AMD 0x8C93 645bd8deadSopenharmony_ci ATC_RGBA_INTERPOLATED_ALPHA_AMD 0x87EE 655bd8deadSopenharmony_ci 665bd8deadSopenharmony_ciAdditions to Chapter 2 of the OpenGL 1.3 Specification (OpenGL Operation) 675bd8deadSopenharmony_ci 685bd8deadSopenharmony_ci None. 695bd8deadSopenharmony_ci 705bd8deadSopenharmony_ciAdditions to Chapter 3 of the OpenGL 1.3 Specification (Rasterization) 715bd8deadSopenharmony_ci 725bd8deadSopenharmony_ci Add to Table 3.17: Specific Compressed Internal Formats 735bd8deadSopenharmony_ci 745bd8deadSopenharmony_ci Compressed Internal Format Base Internal Format 755bd8deadSopenharmony_ci =============================== ==================== 765bd8deadSopenharmony_ci ATC_RGB_AMD RGB 775bd8deadSopenharmony_ci ATC_RGBA_EXPLICIT_ALPHA_AMD RGBA 785bd8deadSopenharmony_ci ATC_RGBA_INTERPOLATED_ALPHA_AMD RGBA 795bd8deadSopenharmony_ci 805bd8deadSopenharmony_ci 815bd8deadSopenharmony_ci Add to Section 3.8.3, Alternate Image Specification 825bd8deadSopenharmony_ci 835bd8deadSopenharmony_ci The details of these formats is not disclosed, so refer to AMD's 845bd8deadSopenharmony_ci Compressonator tool in order to encode your textures offline: 855bd8deadSopenharmony_ci http://ati.amd.com/developer/compressonator.html 865bd8deadSopenharmony_ci 875bd8deadSopenharmony_ci OpenGL ES requires that all mip-levels have to be specified when 885bd8deadSopenharmony_ci CompressedTexImage2D is called to load a palettized texture. In this case 895bd8deadSopenharmony_ci the "level" value is either 0 or a negative number to indicate the number of 905bd8deadSopenharmony_ci mip-levels. This rule is not followed when loading an ATC texture. The 915bd8deadSopenharmony_ci "level" number in this case represents the actual mip-level number, 925bd8deadSopenharmony_ci so a negative number will raise an error. 935bd8deadSopenharmony_ci 945bd8deadSopenharmony_ci Compressed texture images stored using the ATC compressed image formats are 955bd8deadSopenharmony_ci represented as a collection of 4x4 texel blocks. 965bd8deadSopenharmony_ci 975bd8deadSopenharmony_ci ATC_RGB_AMD Format 985bd8deadSopenharmony_ci ================== 995bd8deadSopenharmony_ci 1005bd8deadSopenharmony_ci This format compresses blocks of source texels down to 4 bits per texel. 1015bd8deadSopenharmony_ci Assuming 8-bit component source texels, this represents a 8:1 compression 1025bd8deadSopenharmony_ci ratio. This is the best format to use when no alpha channel is needed. 1035bd8deadSopenharmony_ci 1045bd8deadSopenharmony_ci ATC_RGBA_EXPLICIT_ALPHA_AMD Format 1055bd8deadSopenharmony_ci ================================== 1065bd8deadSopenharmony_ci 1075bd8deadSopenharmony_ci This format compresses blocks of source texels down to 8 bits per texel. 1085bd8deadSopenharmony_ci Assuming 8-bit component source texels, this represents a 4:1 compression 1095bd8deadSopenharmony_ci ratio. This is generally the best format to use when alpha transitions are 1105bd8deadSopenharmony_ci sharp. 1115bd8deadSopenharmony_ci 1125bd8deadSopenharmony_ci ATC_RGBA_INTERPOLATED_ALPHA_AMD Format 1135bd8deadSopenharmony_ci ====================================== 1145bd8deadSopenharmony_ci 1155bd8deadSopenharmony_ci This format compresses blocks of source texels down to 8 bits per texel. 1165bd8deadSopenharmony_ci Assuming 8-bit component source texels, this represents a 4:1 compression 1175bd8deadSopenharmony_ci ratio. This is generally the best format to use when alpha transitions are 1185bd8deadSopenharmony_ci gradient. 1195bd8deadSopenharmony_ci 1205bd8deadSopenharmony_ci The size in bytes of a compressed ATC_RGB_AMD image is: 1215bd8deadSopenharmony_ci 1225bd8deadSopenharmony_ci ((width_in_texels+3)/4) * ((height_in_texels+3)/4) * 8 1235bd8deadSopenharmony_ci 1245bd8deadSopenharmony_ci The size in bytes of a compressed ATC_RGBA_EXPLICIT_ALPHA_AMD or 1255bd8deadSopenharmony_ci ATC_RGBA_INTERPOLATED_ALPHA_AMD image is: 1265bd8deadSopenharmony_ci 1275bd8deadSopenharmony_ci ((width_in_texels+3)/4) * ((height_in_texels+3)/4) * 16 1285bd8deadSopenharmony_ci 1295bd8deadSopenharmony_ciErrors 1305bd8deadSopenharmony_ci 1315bd8deadSopenharmony_ci INVALID_OPERATION is generated by TexImage2D, TexSubImage2D, 1325bd8deadSopenharmony_ci CompressedTexSubImage2D, or CopyTexSubImage2D if <internalformat> or 1335bd8deadSopenharmony_ci <format> is ATC_RGB_AMD, ATC_RGBA_EXPLICIT_ALPHA_AMD, or 1345bd8deadSopenharmony_ci ATC_RGBA_INTERPOLATED_ALPHA_AMD. 1355bd8deadSopenharmony_ci 1365bd8deadSopenharmony_ciNew State 1375bd8deadSopenharmony_ci 1385bd8deadSopenharmony_ci The queries for NUM_COMPRESSED_TEXTURE_FORMATS and 1395bd8deadSopenharmony_ci COMPRESSED_TEXTURE_FORMATS include ATC_RGB_AMD, ATC_RGBA_EXPLICIT_ALPHA_AMD, 1405bd8deadSopenharmony_ci and ATC_RGBA_INTERPOLATED_ALPHA_AMD. 1415bd8deadSopenharmony_ci 1425bd8deadSopenharmony_ciRevision History 1435bd8deadSopenharmony_ci 1445bd8deadSopenharmony_ci 09/06/2012 Maurice Ribble Update contact and add block size data. 1455bd8deadSopenharmony_ci 02/26/2008 Benj Lipchak Throw INVALID_OPERATION on subimage updates. 1465bd8deadSopenharmony_ci 10/24/2007 Benj Lipchak Add interpolated alpha RGBA format. 1475bd8deadSopenharmony_ci 09/24/2007 Jon Leech Assign extension number. 1485bd8deadSopenharmony_ci 09/05/2007 Benj Lipchak Cosmetic changes. 1495bd8deadSopenharmony_ci 08/01/2007 Benj Lipchak Publication readiness. 1505bd8deadSopenharmony_ci 07/07/2005 Aaftab Munshi Fixed typos. 1515bd8deadSopenharmony_ci 09/15/2004 Aaftab Munshi Created the document. 152