March 2013
Intermediate to advanced
984 pages
26h 18m
English
Some applications require a number of texels around a region of interest, or may need to offset the texture coordinates slightly during sampling. GLSL includes functions for doing this that will likely be more efficient than physically offsetting the texture coordinates in the shader. This functionality is exposed through an overloaded set of texture lookup functions called textureOffset with some example prototypes as follows: (A full list is in Appendix C, “Built-in GLSL Variables and Functions”.)