The value of a sampler indicates the
texture image unit being accessed. Setting a sampler's value to i selects texture
image unit number i. The values of i range from zero to the maximum supported number
of texture image units. This maximum is implementation dependent, and defined in other
The type of the sampler identifies the target on the texture image unit. The texture
object bound to that texture image unit's target is then used for the texture lookup.
For example, a variable of type sampler2D selects target TEXTURE_2D on its texture