Fixed bug in gl.bindTexture which tried to use an undefined private var.