System info & network
This commit is contained in:
23
shaders/postprocessing.frag
Normal file
23
shaders/postprocessing.frag
Normal file
@@ -0,0 +1,23 @@
|
||||
#version 430 core
|
||||
|
||||
out vec4 FragColor;
|
||||
|
||||
in vec2 frag_uv;
|
||||
|
||||
uniform sampler2D texture0; // rendered 3D
|
||||
uniform sampler2D texture1; // rendered HUD
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
vec3 hdr_color = texture(texture0, frag_uv).rgb;
|
||||
|
||||
// HDR - TODO
|
||||
vec3 sdr_color = min(hdr_color, 1.0);
|
||||
|
||||
|
||||
vec4 hud_color = texture(texture1, frag_uv);
|
||||
|
||||
vec3 mixed = mix(sdr_color, hud_color.rgb, hud_color.a); // TODO: SDR color
|
||||
FragColor = vec4(mixed, 1.0);
|
||||
}
|
||||
Reference in New Issue
Block a user