| 1 | uniform mat4 u_mvpMatrix; |
| 2 | uniform vec3 texSize; |
| 3 | |
| 4 | attribute vec4 a_position; |
| 5 | attribute vec3 a_texCoord; |
| 6 | |
| 7 | varying vec4 scaled; |
| 8 | varying vec2 pos; |
| 9 | varying vec2 videoCoord; |
| 10 | |
| 11 | void main() |
| 12 | { |
| 13 | gl_Position = u_mvpMatrix * a_position; |
| 14 | vec2 tmp = a_texCoord.xy * texSize.xy; |
| 15 | scaled = tmp.xxxy + vec4(0.0, 1.0/3.0, 2.0/3.0, 0.5); |
| 16 | pos = a_texCoord.xy; |
| 17 | #if SUPERIMPOSE |
| 18 | videoCoord = a_texCoord.xz; |
| 19 | #endif |
| 20 | } |