3 <extension href="WEBGL_compressed_texture_etc1/">
4 <name>WEBGL_compressed_texture_etc1</name>
6 <a href="https://www.khronos.org/webgl/public-mailing-list/">WebGL working group</a> (public_webgl 'at' khronos.org)
9 <contributor>Members of the WebGL working group</contributor>
17 This extension exposes the compressed texture format defined in the
18 <a href="http://www.khronos.org/registry/gles/extensions/OES/OES_compressed_ETC1_RGB8_texture.txt">
19 OES_compressed_ETC1_RGB8_texture</a> OpenGL ES extension to WebGL.
23 Compression format <code>COMPRESSED_RGB_ETC1_WEBGL</code> may be passed to
24 the <code>compressedTexImage2D</code> entry point.
26 This format correspond to the format defined in the OES_compressed_ETC1_RGB8_texture OpenGL ES
27 extension. Although the enum name is changed, the numeric value is the same. The correspondence
28 is given by this table:
31 <th>WebGL format enum</th>
32 <th>OpenGL format enum</th>
33 <th>Numeric value</th>
36 <td>COMPRESSED_RGB_ETC1_WEBGL</td>
37 <td>ETC1_RGB8_OES</td>
43 Calling <code>getParameter</code> with the argument <code>COMPRESSED_TEXTURE_FORMATS</code>
44 will include the format from this specification.
47 <p>The following format-specific restrictions must be enforced:</p>
49 <dt>COMPRESSED_RGB_ETC1_WEBGL</dt>
50 <dd><p>The <code>byteLength</code> of the ArrayBufferView, <code>pixels</code>, passed to
51 <code>compressedTexImage2D</code> must be equal to the following number of bytes:</p>
53 floor((width + 3) / 4) * floor((height + 3) / 4) * 8
55 <p>If it is not, an <code>INVALID_VALUE</code> error is generated.</p>
61 <idl xml:space="preserve">
63 interface WEBGL_compressed_texture_etc1 {
64 /* Compressed Texture Format */
65 const GLenum COMPRESSED_RGB_ETC1_WEBGL = 0x8D64;
69 <revision date="2012/02/23">
70 <change>Initial revision.</change>
72 <revision date="2013/07/03">
73 <change>Clarified that length of ArrayBufferView is actually byteLength.</change>
75 <revision date="2013/11/27">
76 <change>Moved to draft status.</change>
78 <revision date="2013/12/03">
79 <change>Assigned extension number 24 to WEBGL_compressed_texture_etc1 extension.</change>
81 <revision date="2014/03/07">
82 <change>Remove ability to use the format with compressedTexSubImage2D, as per the GLES extension spec.</change>
84 <revision date="2014/06/27">
85 <change>Moved to community approved after discussion on public_webgl list.</change>
87 <revision date="2014/07/15">
88 <change>Added NoInterfaceObject extended attribute.</change>