Mercurial > hg > forks > bilotrip-mj12
view liboggplayer-src/bin/yuv2rgb.frag @ 14:083c73ceb716
Get rid of the vorbis related code.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 05 Aug 2013 16:54:46 +0300 |
parents | 105513a2e3c9 |
children |
line wrap: on
line source
uniform sampler2D y_tex; uniform sampler2D u_tex; uniform sampler2D v_tex; void main (void) { float y = texture2D(y_tex, vec2(gl_TexCoord[0])).r; float u = texture2D(u_tex, vec2(gl_TexCoord[0])).r-0.5; float v = texture2D(v_tex, vec2(gl_TexCoord[0])).r-0.5; float r = y + 1.13983*v; float g = y - 0.39465*u-0.58060*v; float b = y + 2.03211*u; gl_FragColor = vec4(r,g,b,1); }