gfx/angle/extensions/ANGLE_texture_compression_dxt.txt

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/gfx/angle/extensions/ANGLE_texture_compression_dxt.txt	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,163 @@
     1.4 +Name
     1.5 +
     1.6 +    ANGLE_texture_compression_dxt
     1.7 +
     1.8 +Name Strings
     1.9 +
    1.10 +    GL_ANGLE_texture_compression_dxt1
    1.11 +    GL_ANGLE_texture_compression_dxt3
    1.12 +    GL_ANGLE_texture_compression_dxt5
    1.13 +
    1.14 +Contributors
    1.15 +
    1.16 +    Gregg Tavares, Google Inc.
    1.17 +    Daniel Koch, TransGaming Inc.
    1.18 +    Al Patrick, Google Inc.
    1.19 +
    1.20 +Contacts
    1.21 +
    1.22 +    Gregg Tavares, Google Inc. (gman 'at' google 'dot' com)
    1.23 +
    1.24 +Status
    1.25 +
    1.26 +    Implemented in ANGLE ES2
    1.27 +
    1.28 +Version
    1.29 +
    1.30 +    Last Modified Date: Sept 22, 2012
    1.31 +    Author Revision: 2
    1.32 +
    1.33 +Number
    1.34 +
    1.35 +    OpenGL ES Extension #111
    1.36 +
    1.37 +Dependencies
    1.38 +
    1.39 +    Requires OpenGL ES 1.0.
    1.40 +
    1.41 +    The extension is written against the OpenGL ES 2.0 specification.
    1.42 +
    1.43 +Overview
    1.44 +
    1.45 +    These extensions are exactly the same as EXT_texture_compression_dxt1
    1.46 +    except they additionally expose the COMPRESSED_RGBA_S3TC_DXT3_ANGLE and
    1.47 +    COMPRESSED_RGBA_S3TC_DXT5_ANGLE formats and have a size restrictions
    1.48 +    such that the size must be a multiple of four (except for mip levels
    1.49 +    where the dimensions are either 2 or 1).
    1.50 +
    1.51 +    See EXT_texture_compression_dxt1 for the full list of changes. Also
    1.52 +    see EXT_texture_compression_s3tc for a description of the formats.
    1.53 +
    1.54 +IP Status
    1.55 +
    1.56 +    A license to the S3TC Intellectual Property may be necessary for 
    1.57 +    implementation of this extension.  You should consult with your 
    1.58 +    Attorney to determine the need for a license.
    1.59 +
    1.60 +New Procedures and Functions
    1.61 +
    1.62 +    None.
    1.63 +
    1.64 +New Types
    1.65 +
    1.66 +    None.
    1.67 +
    1.68 +New Tokens
    1.69 +
    1.70 +    Accepted by the <internalformat> parameter of CompressedTexImage2D
    1.71 +    and the <format> parameter of CompressedTexSubImage2D:
    1.72 +
    1.73 +    COMPRESSED_RGB_S3TC_DXT1_ANGLE                    0x83F0
    1.74 +    COMPRESSED_RGBA_S3TC_DXT1_ANGLE                   0x83F1
    1.75 +    COMPRESSED_RGBA_S3TC_DXT3_ANGLE                   0x83F2
    1.76 +    COMPRESSED_RGBA_S3TC_DXT5_ANGLE                   0x83F3
    1.77 +
    1.78 +Additions to Chapter 3 of the OpenGL ES 2.0 Specification (Rasterization)
    1.79 +
    1.80 +    Add the following to Section 3.7.3 (Compressed Texture Images)
    1.81 +    (at the end of the description of the CompressedTexImage2D command):
    1.82 +
    1.83 +    Compressed Internal Format        Base Internal Format
    1.84 +    ==========================        ====================
    1.85 +    COMPRESSED_RGB_S3TC_DXT1_ANGLE    RGB
    1.86 +    COMPRESSED_RGBA_S3TC_DXT1_ANGLE   RGBA
    1.87 +    COMPRESSED_RGBA_S3TC_DXT3_ANGLE   RGBA
    1.88 +    COMPRESSED_RGBA_S3TC_DXT5_ANGLE   RGBA
    1.89 +
    1.90 +    Table 3.x: Specific Compressed Internal Formats
    1.91 +
    1.92 +    If <internalformat> is one of the S3TC formats listed in Table 3.x,
    1.93 +    the compressed texture is stored in the appropriate S3TC compressed
    1.94 +    texture format (see Appendix). The GL and the S3TC texture compression
    1.95 +    algorithm support only 2D images without borders.
    1.96 +
    1.97 +    CompressedTexImage2D will produce the INVALID_OPERATION error when
    1.98 +    <internalformat> is one of the values from Table 3.x under the following
    1.99 +    conditions: 
   1.100 +
   1.101 +      * <border> is non-zero.
   1.102 +      * <width> is not one, two, or a multiple of four.
   1.103 +      * <height> is not one, two, or a multiple of four.
   1.104 +
   1.105 +    Add the following to Section 3.7.3 (Compressed Texture Images)
   1.106 +    (at the end of the description of the CompressedTexSubImage2D command):
   1.107 +
   1.108 +    If the internal format of the texture image being modified is listed
   1.109 +    in Table 3.x, the texture is stored in the appropriate S3TC compressed
   1.110 +    texture format (see Appendix). Since DXT/S3TC images are easily edited
   1.111 +    along 4x4 texel boundaries, the limitations of CompressedTexSubImage2D
   1.112 +    are relaxed. CompressedTexSubImage2D will result in an INVALID_OPERATION
   1.113 +    error only if one of the following conditions occurs:
   1.114 +
   1.115 +      * <width> is not a multiple of four or equal to TEXTURE_WIDTH.
   1.116 +      * <height> is not a multipls of four or equal to TEXTURE_HEIGHT.
   1.117 +      * <xoffset> or <yoffset> is not a multiple of four.
   1.118 +      * <format> does not match the internal format of the texture image
   1.119 +        being modified.
   1.120 +
   1.121 +    The following restrictions at the end of section 3.7.3 do not apply
   1.122 +    to S3TC DXT texture formats, since subimage modification is straightforward
   1.123 +    as long as the subimage is properly aligned.
   1.124 +
   1.125 +Errors
   1.126 +
   1.127 +    INVALID_OPERATION is generated by CompressedTexImage2D if <internalformat>
   1.128 +    is one of the compressed internal formats from Table 3.x and any of the 
   1.129 +    following apply:
   1.130 +      - <border> is not equal to zero.
   1.131 +      - <width> is not one, two, or a multiple of four. 
   1.132 +      - <height> is not one, two, or a multiple of four. 
   1.133 +
   1.134 +    INVALID_OPERATION is generated by TexImage2D and CopyTexImage2D if
   1.135 +    <internalformat> is one of the compressed internal formats from
   1.136 +    Table 3.x.
   1.137 +
   1.138 +    INVALID_OPERATION is generated by TexSubImage2D and CopyTexSubImage2D
   1.139 +    if the internal format of the texture currently bound to <target> is
   1.140 +    one of the compressed internal formats from Table 3.x.
   1.141 +
   1.142 +    INVALID_OPERATION is generated by CompressedTexSubImage2D if <format>
   1.143 +    is one of the compressed interal formats from Table 3.x and any of the
   1.144 +    following apply:
   1.145 +      - <width> is not a multiple of four or equal to TEXTURE_WIDTH;
   1.146 +      - <height> is not a multiple of four or equal to TEXTURE_HEIGHT;
   1.147 +      - <xoffset> or <yoffset> is not a multiple of four;
   1.148 +      - <format> does not match the internal format of the texture image
   1.149 +      being modified.
   1.150 +
   1.151 +New State
   1.152 +
   1.153 +    None.
   1.154 +
   1.155 +Appendix: 
   1.156 +
   1.157 +    The format for the S3TC Compressed Texture Images Formats is documented
   1.158 +    in the appendix of EXT_texture_compression_s3tc.
   1.159 +
   1.160 +Revision History
   1.161 +
   1.162 +    Revision 1, 2010/08/06 - gman
   1.163 +      - Initial revision
   1.164 +    Revision 2, 2012/09/22 - dgkoch
   1.165 +      - Added DXT1 formats and documented multiple of 4 restriction.
   1.166 +

mercurial