gl-checker-texture
Creates a 2x2 checkered repeating WebGL texture. Useful for checkered backgrounds, dotted lines, etc.
var Checker = var tex = tex
Usage
createTexture(gl[, opt])
Creates a new 2x2 texture with the given options:
colors
an array of two RGBA colors in bytes. Defaults to #ffffff and #cccccc.
Example:
var tex =
The new texture is set to gl.REPEAT
wrap and gl.NEAREST
filtering.
License
MIT, see LICENSE.md for details.