blob: 43452a1f11b051589df7e2d68071817d6ec3e840 [file] [log] [blame]
John Kessenichf6eae2a2016-01-22 17:47:22 -07001#version 310 es
John Kessenich39374da2015-05-15 21:32:46 +00002
3lowp float foo();
4
John Kessenich6c292d32016-02-15 20:58:50 -07005in lowp float low, high;
John Kessenich39374da2015-05-15 21:32:46 +00006
7lowp float face1 = 11.0;
8
John Kessenichf6eae2a2016-01-22 17:47:22 -07009out lowp vec4 Color;
10
John Kessenich39374da2015-05-15 21:32:46 +000011void main()
12{
13 int z = 3;
14
John Kessenich6c292d32016-02-15 20:58:50 -070015 if (2.0 * low + 1.0 < high)
John Kessenich39374da2015-05-15 21:32:46 +000016 ++z;
17
John Kessenichf6eae2a2016-01-22 17:47:22 -070018 Color = face1 * vec4(z) + foo();
John Kessenich39374da2015-05-15 21:32:46 +000019}
20
21lowp float face2 = -2.0;
22
23lowp float foo()
24{
25 // testing if face2 initializer insert logic is correct in main
26 return face2;
27}