mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
Change all the post processing shaders to the new system.
Removes the README.txt file in favour of a new wiki page I'm going to generate.
This commit is contained in:
@ -1,26 +1,19 @@
|
||||
SAMPLER_BINDING(9) uniform sampler2D samp9;
|
||||
|
||||
out vec4 ocol0;
|
||||
in vec2 uv0;
|
||||
|
||||
uniform vec4 resolution;
|
||||
|
||||
void main()
|
||||
{
|
||||
float4 emboss = (texture(samp9, uv0+resolution.zw) - texture(samp9, uv0-resolution.zw))*2.0;
|
||||
emboss -= (texture(samp9, uv0+float2(1,-1)*resolution.zw).rgba - texture(samp9, uv0+float2(-1,1)*resolution.zw).rgba);
|
||||
float4 color = texture(samp9, uv0).rgba;
|
||||
float4 emboss = (SampleLocation(GetCoordinates()+GetInvResolution()) - SampleLocation(GetCoordinates()-GetInvResolution()))*2.0;
|
||||
emboss -= (SampleLocation(GetCoordinates()+float2(1,-1)*GetInvResolution()).rgba - SampleLocation(GetCoordinates()+float2(-1,1)*GetInvResolution()).rgba);
|
||||
float4 color = Sample();
|
||||
|
||||
if (color.r > 0.8 && color.b + color.b < 0.2)
|
||||
{
|
||||
ocol0 = float4(1,0,0,0);
|
||||
SetOutput(float4(1,0,0,0));
|
||||
}
|
||||
else
|
||||
{
|
||||
color += emboss;
|
||||
if (dot(color.rgb, float3(0.3, 0.5, 0.2)) > 0.5)
|
||||
ocol0 = float4(1,1,1,1);
|
||||
SetOutput(float4(1,1,1,1));
|
||||
else
|
||||
ocol0 = float4(0,0,0,0);
|
||||
SetOutput(float4(0,0,0,0));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user