on bce304a help sign in
42 lines 654 B history raw
1#version 330 core
3#ifdef TEST
4layout (location = 0) in vec4 vertex;
5#else
6layout (location = 6) in vec4 vertex;
7#endif
9out vec2 p_textureVertex;
11/*
12 * This stores offsets
13 */
14struct Data
16 double offsetX;
17 double offsetY;
20uniform mat4 projectionMatrix;
21uniform bool test;
22uniform Data data;
24double calc()
26 if (test)
27 {
28 return 1.0;
29 }
30 else
31 {
32 return 0.0;
33 }
36void main()
38 // This GLSL code serves the purpose of bat syntax highlighting tests
39 double x = data.offsetX + calc();
40 gl_Position = projectionMatrix * vec4(vertex.xy, data.offsetX, data.offsetY);
41 p_textureVertex = vertex.zw;