Fixed check for depth texture mode

Change-Id: Ie46aa094fddb29b597b3b4110b0001529ba04e1b
Apply scale and bias in the shader

glPixelTransfer is deprecated in 3.3 and onwards

Change-Id: I6066431edec2cdcbcf7de1cd95b3204eb0608beb
Added ability to set texture attributes directly

Change-Id: If464761f47c7555f68a061e4657711ab7d1173c2