mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-09-30 21:28:45 +00:00
PostProcessing: Add support for user-supplied anaglyph shaders.
There are lots of different anaglyph glasses out there and there may be even more creative uses for stereoscopic post-processing shaders.
This commit is contained in:
parent
a93433a860
commit
262c3b19ec
14 changed files with 110 additions and 58 deletions
10
Data/Sys/Shaders/Anaglyph/grayscale.glsl
Normal file
10
Data/Sys/Shaders/Anaglyph/grayscale.glsl
Normal file
|
@ -0,0 +1,10 @@
|
|||
// Anaglyph Red-Cyan grayscale shader
|
||||
|
||||
void main()
|
||||
{
|
||||
float4 c0 = SampleLayer(0);
|
||||
float avg0 = (c0.r + c0.g + c0.b) / 3.0;
|
||||
float4 c1 = SampleLayer(1);
|
||||
float avg1 = (c1.r + c1.g + c1.b) / 3.0;
|
||||
SetOutput(float4(avg0, avg1, avg1, c0.a));
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue