1
0
Fork 0
fgdata/Shaders/HDR/geometry-chrome.frag

24 lines
531 B
GLSL
Raw Normal View History

2021-08-25 12:32:22 +00:00
#version 330 core
layout(location = 0) out vec4 outGBuffer0;
layout(location = 1) out vec4 outGBuffer1;
layout(location = 2) out vec4 outGBuffer2;
2021-08-25 12:32:22 +00:00
in vec3 normalVS;
const float CHROME_METALNESS = 1.0;
const float CHROME_ROUGHNESS = 0.1;
2021-08-25 12:32:22 +00:00
vec2 encodeNormal(vec3 n);
void main()
{
outGBuffer0.rg = encodeNormal(normalVS);
outGBuffer0.b = CHROME_ROUGHNESS;
outGBuffer0.a = 1.0;
outGBuffer1.rgb = vec3(1.0);
outGBuffer1.a = CHROME_METALNESS;
outGBuffer2.rgb = vec3(0.0);
outGBuffer2.a = 1.0;
2021-08-25 12:32:22 +00:00
}