SPIRV-Cross/reference/shaders/asm/frag/unknown-depth-state.asm.vk.frag.vk
Hans-Kristian Arntzen e044732896 Support OpTypeImage with depth == 2 (unknown) properly.
Track which OpSampledImages are ever used with Dref opcodes.
2018-07-04 14:26:23 +02:00

25 lines
530 B
Plaintext

#version 450
layout(set = 0, binding = 0) uniform sampler2DShadow uShadow;
layout(set = 0, binding = 1) uniform texture2D uTexture;
layout(set = 0, binding = 2) uniform samplerShadow uSampler;
layout(location = 0) in vec3 vUV;
layout(location = 0) out float FragColor;
float sample_combined()
{
return texture(uShadow, vec3(vUV.xy, vUV.z));
}
float sample_separate()
{
return texture(sampler2DShadow(uTexture, uSampler), vec3(vUV.xy, vUV.z));
}
void main()
{
FragColor = sample_combined() + sample_separate();
}