fglBindTextureEXT(3G)
fglBindTextureEXT - bind a named texture to a texturing target
As shipped in IRIX 6.5. First release of IRIX 6.5.
NAME fglBindTextureEXT - bind a named texture to a texturing target FORTRAN SPECIFICATION SUBROUTINE fglBindTextureEXT( INTEGER*4 target, INTEGER*4 texture ) PARAMETERS target The target to which the texture will be bound. Must be one of GL_TEXTURE_1D, GL_TEXTURE_2D, GL_DETAIL_TEXTURE_2D_SGIS, or GL_TEXTURE_3D_EXT. texture The name of a texture. DESCRIPTION fglBindTextureEXT is part of the EXT_texture_object extension. This extension makes it possible to use named 1-, 2-, and 3-dimensional textures in addition to the usual OpenGL texture targets designated by GL_TEXTURE_1D, GL_TEXTURE_2D, etc. Texture names are unsigned integers. The value zero is reserved to represent the default texture for each texture target. Texture names and the corresponding texture contents are local to the shared display-list space (see fglXCreateContext) of the current OpenGL rendering context; two rendering contexts will share texture names only if they also share display lists. To create a named texture, simply bind a previously-unused texture name to one of the texture targets listed above. This can be accomplished by calling fglBindTextureEXT with target set to the appropriate texture target, and texture set to the name of the new texture. When a texture is bound to a target, the previous binding for that target is automatically broken. Note that fglGenTexturesEXT may be used to generate a set of fresh texture names. When a texture is first bound it assumes the dimensionality of its target: A texture first bound to GL_TEXTURE_1D becomes 1-dimensional, a texture first bound to GL_TEXTURE_2D becomes 2-dimensional, and so on. The state of a 1-dimensional texture immediately after it is first bound is equivalent to the state of the default GL_TEXTURE_1D at GL initialization, and similarly for 2- and 3-dimensional textures. That is, if the application sets texture parameter values for one texture, those parameter values are not automatically propagated to the next texture that the application binds; each newly-created texture receives a fresh copy of the default texture state. See fglTexParameter for more information about texture parameters and their default values. While a texture is bound, GL operations on the target to which it is bound affect the bound texture, and queries of the target to which it is bound return state from the bound texture. If texture mapping of the dimensionality of the target to which a texture is bound is active, the bound texture is used. In effect, the texture targets become aliases for the textures currently bound to them, and the texture name zero refers to the default textures that were bound to them at initialization. A texture binding created with fglBindTextureEXT remains active until a different texture is bound to the same target, or until the bound texture is deleted with fglDeleteTexturesEXT. Once created, a named texture may be re-bound to the appropriate target as often as needed. It is usually much faster to bind an existing named texture to one of the texture targets using fglBindTextureEXT than it is to reload the texture image using fglTexImage*. For additional control over performance, consider using fglPrioritizeTexturesEXT. fglBindTextureEXT is included in display lists. NOTES See fglIntro for more information about using extensions. ERRORS GL_INVALID_ENUM is generated if target is not one of the allowable values. GL_INVALID_OPERATION is generated if texture has a dimensionality and it doesn't match that of target. GL_INVALID_OPERATION is generated if fglBindTextureEXT is executed between the execution of fglBegin and the corresponding execution of fglEnd. ASSOCIATED GETS fglGet with parameter names GL_TEXTURE_1D_BINDING_EXT, GL_TEXTURE_2D_BINDING_EXT, and GL_TEXTURE_3D_BINDING_EXT. MACHINE DEPENDENCIES RealityEngine, RealityEngine2, and VTX systems do not support texture name sharing. Texture names are always local to the rendering context which was active at the time the names were created. The implementation on O2 systems uses a minimum of 64K bytes for every texture object defined. SEE ALSO fglDeleteTexturesEXT, fglGenTexturesEXT, fglGet, fglGetTexParameter, fglIsTextureEXT, fglTexImage1D, fglTexImage2D, fglTexImage3DEXT, fglTexParameter.