]> git.sesse.net Git - nageru/blob - vs.vert
Share VAOs between all the passes. Much less code, less rebinding overhead.
[nageru] / vs.vert
1 #version 450 core
2
3 layout(location=0) in vec2 position;
4 out vec2 tc;
5
6 void main()
7 {
8         // The result of glOrtho(0.0, 1.0, 0.0, 1.0, 0.0, 1.0) is:
9         //
10         //   2.000  0.000  0.000 -1.000
11         //   0.000  2.000  0.000 -1.000
12         //   0.000  0.000 -2.000 -1.000
13         //   0.000  0.000  0.000  1.000
14         gl_Position = vec4(2.0 * position.x - 1.0, 2.0 * position.y - 1.0, -1.0, 1.0);
15         tc = position;
16 }