kwin/effects/data/cylinder.frag
Martin Gräßlin 89c2ad7c4b Move Cube effect to trunk
svn path=/trunk/KDE/kdebase/workspace/; revision=832912
2008-07-15 19:21:50 +00:00

15 lines
324 B
GLSL

uniform sampler2D winTexture;
uniform float windowWidth;
uniform float windowHeight;
uniform float opacity;
vec2 pix2tex(vec2 pix)
{
return vec2(pix.x / windowWidth, pix.y / windowHeight);
}
void main()
{
gl_FragColor.rgba = texture2D(winTexture, pix2tex(gl_TexCoord[0].xy)).rgba;
gl_FragColor.a *= opacity;
}