GLBINDIMAGETEXTURES(3G)

    .SH "NAME" glBindImageTextures - bind one or more named texture images to a sequence of consecutive image units
    .SH "C SPECIFICATION"

            .HP u void glBindImageTextures(GLuint first, GLsizei count, const GLuint *textures);

    .SH "PARAMETERS"

        .PP first

                    Specifies the first image unit to which a texture is to be bound.

            .RE
            .PP count

                        Specifies the number of textures to bind.

                .RE
                .PP textures

                            Specifies the address of an array of names of existing texture objects.

                    .RE

                .SH "DESCRIPTION"
                    .PP glBindImageTextures binds images from an array of existing texture objects to a specified number of consecutive image units. count specifies the number of texture objects whose names are stored in the array textures. That number of texture names are read from the array and bound to the count consecutive texture units starting from first. If the name zero appears in the textures array, any existing binding to the image unit is reset. Any non-zero entry in textures must be the name of an existing texture object. When a non-zero entry in textures is present, the image at level zero is bound, the binding is considered layered, with the first layer set to zero, and the image is bound for read-write access. The image unit format parameter is taken from the internal format of the image at level zero of the texture object. For cube map textures, the internal format of the positive X image of level zero is used. If textures is NULL then it is as if an appropriately sized array containing only zeros had been specified.
                    .PP glBindImageTextures is equivalent to the following pseudo code:

                    for (i = 0; i < count; i++) {
                        if (textures == NULL || textures[i] = 0) {
                            glBindImageTexture(first + i, 0, 0, GL_FALSE, 0, GL_READ_ONLY, GL_R8);
                        } else {
                            glBindImageTexture(first + i, textures[i], 0, GL_TRUE, 0, GL_READ_WRITE, lookupInternalFormat(textures[i]));
                        }
                    }

                .PP Each entry in textures will be checked individually and if found to be invalid, the state for that image unit will not be changed and an error will be generated. However, the state for other texture image units referenced by the command will still be updated.

                .SH "NOTES"
                    .PP glBindImageTextures is available only if the GL version is 4.4 or higher.
                    .PP Note that because glBindImageTextures cannot create new textures (even if a name passed has been previously generated by call to glGenTextures()), names passed to glBindImageTextures must have been bound at least once previously via a call to glBindTexture().

                .SH "ERRORS"
                    .PP GL_INVALID_OPERATION is generated if first + count is greater than the number of image units supported by the implementation.
                    .PP GL_INVALID_OPERATION is generated if any value in textures is not zero or the name of an existing texture object.
                    .PP GL_INVALID_OPERATION error is generated if the internal format of the level zero texture image of any texture in textures is not supported.
                    .PP GL_INVALID_OPERATION error is generated if the width, height, or depth of the level zero texture image of any texture in textures is zero.

                .SH "ASSOCIATED GETS"
                    .PP glGet() with argument GL_TEXTURE_BINDING_1D, GL_TEXTURE_BINDING_2D, GL_TEXTURE_BINDING_3D, GL_TEXTURE_BINDING_1D_ARRAY, GL_TEXTURE_BINDING_2D_ARRAY, GL_TEXTURE_BINDING_RECTANGLE, GL_TEXTURE_BINDING_BUFFER, GL_TEXTURE_BINDING_CUBE_MAP, GL_TEXTURE_BINDING_CUBE_MAP, GL_TEXTURE_BINDING_CUBE_MAP_ARRAY, GL_TEXTURE_BINDING_2D_MULTISAMPLE, or GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY.

                .SH "VERSION SUPPORT"
                    .TS allbox tab(:); l l l l l l l l l l l l l. T{ glBindImageTextures T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}:T{ T}

                .SH "SEE ALSO"
                    .PP glBindTexture(), glBindTextures(), glDeleteTextures(), glGenTextures(), glGet(), glGetTexParameter(), glIsTexture(), glTexStorage1D(), glTexStorage2D(), glTexStorage2DMultisample(), glTexStorage3D(), glTexStorage3DMultisample(), glTexBuffer(), glTexParameter()

                .SH "COPYRIGHT"
                    .PP Copyright © 2013-2014 Khronos Group. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1.0, 8 June 1999. http://opencontent.org/openpub/.

COPYRIGHT
Copyright © 2013-2014 Khronos Group