OpenGL ES 3.0 Cookbook by Singh Parminder

OpenGL ES 3.0 Cookbook by Singh Parminder

Author:Singh, Parminder
Language: eng
Format: epub, azw3
Publisher: Packt Publishing - ebooks Account
Published: 2015-05-30T04:00:00+00:00


There's more...

Texture units can be thought of as buffers that contain texture information and the number of texture units fixed; the number is very specific to the hardware implementation of the OpenGL ES 3.0. This number can be checked by using the GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS macro. The texture object is not directly bound with the shader program. Instead, they are bound to the index of the texture unit.

In the following figure, the texture memory shows 16 texture units. Out of these, only three seem unoccupied (blue in color) and the rest of them are utilized by various texture images. Texture units are uniquely recognized by their index; these can be accessed in the shader program directly, thereby giving a unique capability of multitexturing. Texture units 1 and 2 are accessed in the fragment shader to produce the desired output, as shown in the following figure:



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.