#version 330


layout (location=0) in vec3 vsPosition;
layout (location=1) in vec2 vsTexture;
uniform float xInc;

const vec2 s1 = vec2(-.75, .75);
const vec2 s2 = vec2( .75, .75);
const vec2 s3 = vec2( .75,-.75);
const vec2 s4 = vec2(-.75,-.75);

out vec2 fsUL1;
out vec2 fsUR1;
out vec2 fsLL1;
out vec2 fsLR1;
out vec2 fsUL2;
out vec2 fsUR2;
out vec2 fsLL2;
out vec2 fsLR2;

void main()
{
    gl_Position=vec4(vsPosition.x,vsPosition.y,vsPosition.z,1.0);
    fsUL1 = vsTexture+s1;
    fsUR1 = vsTexture+s2;
    fsLL1 = vsTexture+s3;
    fsLR1 = vsTexture+s4;

    vec2 tmpTex=vsTexture;
    tmpTex.x+=xInc;
    fsUL2 = tmpTex+s1;
    fsUR2 = tmpTex+s2;
    fsLL2 = tmpTex+s3;
    fsLR2 = tmpTex+s4;
}
