#version 330 core

layout(location=0) in vec2 position;
layout(location=1) in vec2 texcoord;

uniform mat4 fullTransformMatrix;
uniform mat4 texcoordTransformMatrix;
uniform vec2 size;

out vec2 Texcoord;

void main()
{
        Texcoord = vec4(texcoordTransformMatrix * vec4( texcoord, 0, 1)).xy;
        gl_Position = fullTransformMatrix * vec4( position.x * size.x, position.y * size.y, 0, 1 );
}

