SPIRV-Cross/shaders-hlsl-no-opt/frag/frag-coord.frag
Hans-Kristian Arntzen fdbc80d131 HLSL: Fix FragCoord.w.
Need to invert it, SM 4.0+ uses W, not 1/W (like Vulkan/GL).
2020-08-20 16:22:48 +02:00

9 lines
120 B
GLSL

#version 450
layout(location = 0) out vec3 FragColor;
void main()
{
FragColor = gl_FragCoord.xyz / gl_FragCoord.w;
}