1 2 3 4 5 6 7 8 9 10 11 12 13
attribute vec2 aVertexPos; attribute vec2 aTextureCoord; uniform mat4 uViewport; uniform vec2 uTranslate; varying highp vec2 vTextureCoord; void main(void) { gl_Position = uViewport * vec4(aVertexPos + uTranslate, 0.0, 1.0); vTextureCoord = aTextureCoord; }