stk-code_catmod/data/shaders/mlaa_offset.vert

16 lines
340 B
GLSL
Raw Normal View History

2014-04-02 18:14:53 -04:00
in vec2 Position;
in vec2 Texcoord;
out vec4 offset[2];
out vec2 uv;
void main() {
2014-04-02 18:14:53 -04:00
gl_Position = vec4(Position, 0., 1.);
vec4 invy = vec4(Texcoord, Texcoord);
// invy.y = 1.0 - invy.y;
uv = invy.st;
2014-06-04 20:56:25 -04:00
offset[0] = invy.xyxy + vec4(-1.0, 0.0, 0.0, 1.0) / screen.xyxy;
offset[1] = invy.xyxy + vec4( 1.0, 0.0, 0.0, -1.0) / screen.xyxy;
}