Path: blob/main_old/extensions/ANGLE_copy_texture_3d.txt
1693 views
Name12ANGLE_copy_texture_3d34Name Strings56GL_ANGLE_copy_texture_3d78Contributors910Brandon Jones, Intel1112Contacts1314Brandon Jones, Intel (brandon1.jones 'at' intel 'dot' com)1516Status1718Implemented.1920Version2122Version 1, 2018-8-82324Dependencies2526OpenGL ES 3.0 required.2728Overview2930This extension adds 3D texture support to the functionality31provided by the CHROMIUM_copy_texture extension. Two new32functions are exported, glCopyTexture3DANGLE and33glCopySubTexture3DANGLE that perform the same copy operations as34glCopyTextureCHROMIUM and glCopySubTextureCHROMIUM, respectively,35on GL_TEXTURE_3D and GL_TEXTURE_2D_ARRAY bound textures.3637New Procedures and Functions3839void CopyTexture3DANGLE(uint sourceId,40int sourceLevel,41enum destTarget,42uint destId,43int destLevel,44int internalFormat,45enum destType,46boolean unpackFlipY,47boolean unpackPremultiplyAlpha,48boolean unpackUnmultiplyAlpha)4950void CopySubTexture3DANGLE(uint sourceId,51int sourceLevel,52enum destTarget,53uint destId,54int destLevel,55int xoffset,56int yoffset,57int zoffset,58int x,59int y,60int z,61sizei width,62sizei height,63sizei depth,64boolean unpackFlipY,65boolean unpackPremultiplyAlpha,66boolean unpackUnmultiplyAlpha)6768Additions to the OpenGL ES 3.0 Specification6970The command7172CopyTexture3DANGLE7374All CopyTexture3DANGLE behavior is the same as75CopyTextureCHROMIUM unless otherwise defined below.7677When source texture doesn't contain a superset of the component78required by <internalFormat>, fill the components by the79following rules.8081source format color components82----------------------------------------83RED (R, 0, 0, 1)84RED_INTEGER (R, 0, 0, 1)85RG (R, G, 0, 1)86RG_INTEGER (R, G, 0, 1)87RGB (R, G, B, 1)88RGB_INTEGER (R, G, B, 1)89RGBA (R, G, B, A)90RGBA_INTEGER (R, G, B, A)91LUMINANCE_ALPHA (L, L, L, A)92LUMINANCE (L, L, L, 1)93ALPHA (0, 0, 0, A)9495INVALID_OPERATION is generated if the format of <sourceId> is not96one of formats in Table 1.1.9798INVALID_ENUM is generated if <destTarget> is not TEXTURE_3D or99TEXTURE_2D_ARRAY.100101INVALID_VALUE is generated if the texture corresponding to102<sourceId> has not been bound as <destTarget>.103104INVALID_OPERATION is generated if <internalFormat> is not one of105the sized internal formats in Table 1.0.106107The command108109CopySubTexture3DANGLE110111All CopySubTexture3DANGLE behavior is the same as112CopySubTextureCHROMIUM unless otherwise defined below.113114<zoffset> specifies a texel offset in the z direction115respectively within the destination texture.116117<z> specifies a texel offset in the z direction respectively118within the source texture.119120<depth> specifies the depth of the texture subimage.121122INVALID_ENUM is generated if <destTarget> is not TEXTURE_3D or123TEXTURE_2D_ARRAY.124125INVALID_VALUE is generated if the texture corresponding to126<sourceId> and <destId> have not been bound as <destTarget>.127128INVALID_VALUE is generated if either <sourceId> texture or129<destId> texture is not defined.130131INVALID_OPERATION is generated if the format of <sourceId> or132<destId> is not one of formats in Table 1.1.133134INVALID_VALUE is generated if zoffset is less than 0.135136INVALID_VALUE is generated if z is less than 0.137138INVALID_VALUE is generated if depth is less than 0.139140INVALID_VALUE is generated if (<z> + <depth>) > srcDepth.141142INVALID_VALUE is generated if (<zoffset> + <depth>) > destDepth.143144Table 1.0 internal formats for CopyTexture3DANGLE:145146<internalFormat>147---------------148RGB149RGBA150LUMINANCE151LUMINANCE_ALPHA152ALPHA153R8154R8_SNORM155R16F156R32F157R8UI158R8I159R16UI160R16I161R32UI162R32I163RG8164RG8_SNORM165RG16F166RG32F167RG8UI168RG8I169RG16UI170RG16I171RG32UI172RG32I173RGB8174SRGB8175RGB565176RGB8_SNORM177R11F_G11F_B10F178RGB9_E5179RGB16F180RGB32F181RGB8UI182RGB8I183RGB16UI184RGB16I185RGB32UI186RGB32I187RGBA8188SRGB8_ALPHA8189RGBA8_SNORM190RGB5_A1191RGBA4192RGB10_A2193RGBA16F194RGBA32F195RGBA8UI196RGBA8I197RGB10_A2UI198RGBA16UI199RGBA16I200RGBA32I201RGBA32UI202203Table 1.1 Valid source texture formats for204CopyTexture3DANGLE and source and destination formats for205CopySubTexture3DANGLE:206207Format208---------------209RED210RED_INTEGER211RG212RG_INTEGER213RGB214RGB_INTEGER215RGBA216RGBA_INTEGER217LUMINANCE_ALPHA218LUMINANCE219ALPHA220221Revision History222223Version 1, 2018-8-8 (Brandon Jones)224- Initial implementation.225226