| 1 |
#version 310 es |
| 2 |
precision mediump float; |
| 3 |
|
| 4 |
layout(set = 0, binding = 0) uniform mediump sampler2D uSampler; |
| 5 |
layout(set = 0, binding = 1) uniform mediump sampler2DShadow uSamplerShadow; |
| 6 |
layout(location = 0) out float FragColor; |
| 7 |
|
| 8 |
vec4 samp2(sampler2D s) |
| 9 |
{ |
| 10 |
return texture(s, vec2(1.0)) + texelFetch(s, ivec2(10), 0); |
| 11 |
} |
| 12 |
|
| 13 |
vec4 samp3(sampler2D s) |
| 14 |
{ |
| 15 |
return samp2(s); |
| 16 |
} |
| 17 |
|
| 18 |
float samp4(mediump sampler2DShadow s) |
| 19 |
{ |
| 20 |
return texture(s, vec3(1.0)); |
| 21 |
} |
| 22 |
|
| 23 |
float samp(sampler2D s0, mediump sampler2DShadow s1) |
| 24 |
{ |
| 25 |
return samp3(s0).x + samp4(s1); |
| 26 |
} |
| 27 |
|
| 28 |
void main() |
| 29 |
{ |
| 30 |
FragColor = samp(uSampler, uSamplerShadow); |
| 31 |
} |