• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#version 130
2
3uniform sampler2D sampler;
4varying vec2 coord;
5varying vec4 color;
6
7struct s1 {
8    int i;
9    float f;
10};
11
12struct s2 {
13    int i;
14    float f;
15	s1 s1_1;
16	vec4 bleh;
17};
18
19struct s3 {
20	s2 s2_1;
21    int i;
22    float f;
23	s1 s1_1;
24};
25
26
27uniform s1 foo;
28uniform s2 foo2;
29uniform s3 foo3;
30
31uniform float[16] uFloatArray;
32uniform int condition;
33
34void main()
35{
36	s2 locals2;
37	s3 locals3;
38	float localFArray[16];
39	int localIArray[8];
40
41	locals2 = foo3.s2_1;
42
43	if (foo3.s2_1.i > 0) {
44		locals2.s1_1.f = 1.0;
45		localFArray[4] = coord.x;
46		localIArray[2] = foo3.s2_1.i;
47	} else {
48		locals2.s1_1.f = coord.x;
49		localFArray[4] = 1.0;
50		localIArray[2] = 0;
51	}
52
53	if (localIArray[2] == 0)
54		++localFArray[4];
55
56 	float localArray[16];
57	int x = 5;
58	localArray[x] = coord.x;
59
60	float[16] a;
61
62	for (int i = 0; i < 16; i++)
63		a[i] = 0.0;
64
65	if (condition == 1)
66		a = localArray;
67
68	locals2.bleh = color;
69	locals2.bleh.z = coord.y;
70
71	gl_FragColor = locals2.bleh * (localFArray[4] + locals2.s1_1.f + localArray[x] + a[x]) * texture2D(sampler, coord);
72}
73