Advertisement
_AMDG_

Realism.glsl (Dolphin Post Processing Shader)

Jul 18th, 2019
720
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*
  2.     Realism.fx by Andrew Porter
  3.    
  4.     Makes lighting appear more realistic by making darkness darker and lightness lighter.
  5.    
  6. */
  7.  
  8.  
  9. float4 fshRealism(float4 color) {
  10.     color.a = 0.5f * dot(color.rgb, vec3(0.3333333333333333f));
  11.     color.rgb = (color.rgb * color.a) + color.rgb - (color.a);
  12.    
  13.     return color;
  14. }
  15.  
  16. void main() {
  17.     float4 color = Sample();
  18.     SetOutput(fshRealism(color));
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement