mirror of
https://github.com/italicsjenga/slang-shaders.git
synced 2024-11-22 15:51:30 +11:00
update guest's crt shaders to include some last-minute changes (#365)
This commit is contained in:
parent
2b63603462
commit
356678ec53
|
@ -461,7 +461,7 @@ float SlotMask(vec2 pos, float m)
|
|||
if ((slotmask + slotmask1) == 0.0) return 1.0;
|
||||
else
|
||||
{
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + 1.0;
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + slotms;
|
||||
pos = floor(pos/slotms);
|
||||
float mlen = slotwidth*2.0;
|
||||
float px = fract(pos.x/mlen);
|
||||
|
@ -667,7 +667,7 @@ if ((abs(global.deconrr) + abs(global.deconrry) + abs(global.deconrg) + abs(glob
|
|||
float smask = SlotMask(maskcoord, mx);
|
||||
cmask*= Mask(maskcoord, mx, mb);
|
||||
|
||||
if (mask_layout > 0.5) cmask = cmask.bgr;
|
||||
if (mask_layout > 0.5) cmask = cmask.rbg;
|
||||
|
||||
cmask*=smask;
|
||||
vec3 cmask1 = cmask;
|
||||
|
|
|
@ -464,7 +464,7 @@ float SlotMask(vec2 pos, float m)
|
|||
if ((slotmask + slotmask1) == 0.0) return 1.0;
|
||||
else
|
||||
{
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + 1.0;
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + slotms;
|
||||
pos = floor(pos/slotms);
|
||||
float mlen = slotwidth*2.0;
|
||||
float px = fract(pos.x/mlen);
|
||||
|
@ -672,7 +672,7 @@ if ((abs(global.deconrr) + abs(global.deconrry) + abs(global.deconrg) + abs(glob
|
|||
float smask = SlotMask(maskcoord, mx);
|
||||
cmask*= Mask(maskcoord, mx, mb);
|
||||
|
||||
if (mask_layout > 0.5) cmask = cmask.bgr;
|
||||
if (mask_layout > 0.5) cmask = cmask.rbg;
|
||||
|
||||
cmask*=smask;
|
||||
vec3 cmask1 = cmask;
|
||||
|
|
|
@ -34,6 +34,7 @@ layout(push_constant) uniform Push
|
|||
float iscans;
|
||||
float downsample_levelx;
|
||||
float downsample_levely;
|
||||
float gamma_out;
|
||||
} params;
|
||||
|
||||
|
||||
|
@ -43,10 +44,14 @@ layout(std140, set = 0, binding = 0) uniform UBO
|
|||
mat4 MVP;
|
||||
} global;
|
||||
|
||||
#pragma parameter bogus_gamma "[ GAMMA OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter GAMMA_INPUT " Gamma Input" 2.0 1.0 5.0 0.05
|
||||
#define GAMMA_INPUT params.GAMMA_INPUT
|
||||
|
||||
#pragma parameter gamma_out " Gamma out" 1.95 1.0 5.0 0.05
|
||||
#define gamma_out params.gamma_out // output gamma
|
||||
|
||||
#pragma parameter bogus_interlacing "[ INTERLACING OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter inter " Interlace Trigger Resolution :" 400.0 0.0 800.0 25.0
|
||||
|
|
|
@ -34,6 +34,7 @@ layout(push_constant) uniform Push
|
|||
float iscans;
|
||||
float downsample_levelx;
|
||||
float downsample_levely;
|
||||
float gamma_out;
|
||||
} params;
|
||||
|
||||
|
||||
|
@ -44,9 +45,14 @@ layout(std140, set = 0, binding = 0) uniform UBO
|
|||
} global;
|
||||
|
||||
|
||||
#pragma parameter bogus_gamma "[ GAMMA OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter GAMMA_INPUT " Gamma Input" 2.4 1.0 5.0 0.05
|
||||
#define GAMMA_INPUT params.GAMMA_INPUT
|
||||
|
||||
#pragma parameter gamma_out " Gamma out" 2.4 1.0 5.0 0.05
|
||||
#define gamma_out params.gamma_out // output gamma
|
||||
|
||||
#pragma parameter bogus_interlacing "[ INTERLACING OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter inter " Interlace Trigger Resolution :" 400.0 0.0 800.0 25.0
|
||||
|
|
|
@ -465,7 +465,7 @@ float SlotMask(vec2 pos, float m)
|
|||
if ((slotmask + slotmask1) == 0.0) return 1.0;
|
||||
else
|
||||
{
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + 1.0;
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + slotms;
|
||||
pos = floor(pos/slotms);
|
||||
float mlen = slotwidth*2.0;
|
||||
float px = fract(pos.x/mlen);
|
||||
|
@ -731,7 +731,7 @@ if (abs(vertmask) > 0.025)
|
|||
float smask = SlotMask(gl_FragCoord.xy * 1.000001, mx);
|
||||
cmask*= Mask(gl_FragCoord.xy * 1.000001, mx);
|
||||
|
||||
if (mask_layout > 0.5) cmask = cmask.bgr;
|
||||
if (mask_layout > 0.5) cmask = cmask.rbg;
|
||||
|
||||
color = color*cmask;
|
||||
color = min(color,1.0);
|
||||
|
|
|
@ -448,7 +448,7 @@ float SlotMask(vec2 pos, float m)
|
|||
if ((slotmask + slotmask1) == 0.0) return 1.0;
|
||||
else
|
||||
{
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + 1.0;
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + slotms;
|
||||
pos = floor(pos/slotms);
|
||||
float mlen = slotwidth*2.0;
|
||||
float px = fract(pos.x/mlen);
|
||||
|
@ -649,7 +649,7 @@ if ((abs(global.deconrr) + abs(global.deconrry) + abs(global.deconrg) + abs(glob
|
|||
float smask = SlotMask(maskcoord, mx);
|
||||
cmask*= Mask(maskcoord, mx, mb);
|
||||
|
||||
if (mask_layout > 0.5) cmask = cmask.bgr;
|
||||
if (mask_layout > 0.5) cmask = cmask.rbg;
|
||||
|
||||
cmask*=smask;
|
||||
vec3 cmask1 = cmask;
|
||||
|
|
|
@ -34,6 +34,7 @@ layout(push_constant) uniform Push
|
|||
float iscans;
|
||||
float downsample_levelx;
|
||||
float downsample_levely;
|
||||
float gamma_out;
|
||||
} params;
|
||||
|
||||
|
||||
|
@ -43,10 +44,15 @@ layout(std140, set = 0, binding = 0) uniform UBO
|
|||
mat4 MVP;
|
||||
} global;
|
||||
|
||||
#pragma parameter bogus_gamma "[ GAMMA OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
|
||||
#pragma parameter GAMMA_INPUT " Gamma Input" 2.4 1.0 5.0 0.05
|
||||
#define GAMMA_INPUT params.GAMMA_INPUT
|
||||
|
||||
#pragma parameter gamma_out " Gamma out" 2.4 1.0 5.0 0.05
|
||||
#define gamma_out params.gamma_out // output gamma
|
||||
|
||||
#pragma parameter bogus_interlacing "[ INTERLACING OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter inter " Interlace Trigger Resolution :" 400.0 0.0 800.0 25.0
|
||||
|
|
|
@ -34,6 +34,7 @@ layout(push_constant) uniform Push
|
|||
float inters;
|
||||
float iscan;
|
||||
float intres;
|
||||
float gamma_out;
|
||||
} params;
|
||||
|
||||
|
||||
|
@ -42,10 +43,14 @@ layout(std140, set = 0, binding = 0) uniform UBO
|
|||
mat4 MVP;
|
||||
} global;
|
||||
|
||||
#pragma parameter bogus_gamma "[ GAMMA OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter GAMMA_INPUT " Gamma Input" 2.4 1.0 5.0 0.05
|
||||
#define GAMMA_INPUT params.GAMMA_INPUT
|
||||
|
||||
#pragma parameter gamma_out " Gamma out" 2.4 1.0 5.0 0.05
|
||||
#define gamma_out params.gamma_out // output gamma
|
||||
|
||||
#pragma parameter bogus_interlacing "[ INTERLACING OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter inter " Interlace Trigger Resolution :" 400.0 0.0 800.0 25.0
|
||||
|
|
|
@ -451,7 +451,7 @@ float SlotMask(vec2 pos, float m)
|
|||
if ((slotmask + slotmask1) == 0.0) return 1.0;
|
||||
else
|
||||
{
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + 1.0;
|
||||
if (shadowMask == 2.0 || shadowMask == 6.0) pos.x = pos.x + slotms;
|
||||
pos = floor(pos/slotms);
|
||||
float mlen = slotwidth*2.0;
|
||||
float px = fract(pos.x/mlen);
|
||||
|
@ -653,7 +653,7 @@ if ((abs(global.deconrr) + abs(global.deconrry) + abs(global.deconrg) + abs(glob
|
|||
float smask = SlotMask(maskcoord, mx);
|
||||
cmask*= Mask(maskcoord, mx, mb);
|
||||
|
||||
if (mask_layout > 0.5) cmask = cmask.bgr;
|
||||
if (mask_layout > 0.5) cmask = cmask.rbg;
|
||||
|
||||
cmask*=smask;
|
||||
vec3 cmask1 = cmask;
|
||||
|
|
|
@ -33,6 +33,7 @@ layout(push_constant) uniform Push
|
|||
float iscan;
|
||||
float intres;
|
||||
float iscans;
|
||||
float gamma_out;
|
||||
} params;
|
||||
|
||||
|
||||
|
@ -42,10 +43,14 @@ layout(std140, set = 0, binding = 0) uniform UBO
|
|||
mat4 MVP;
|
||||
} global;
|
||||
|
||||
#pragma parameter bogus_gamma "[ GAMMA OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter GAMMA_INPUT " Gamma Input" 1.80 1.0 5.0 0.05
|
||||
#define GAMMA_INPUT params.GAMMA_INPUT
|
||||
|
||||
#pragma parameter gamma_out " Gamma out" 1.75 1.0 5.0 0.05
|
||||
#define gamma_out params.gamma_out // output gamma
|
||||
|
||||
#pragma parameter bogus_interlacing "[ INTERLACING OPTIONS ]: " 0.0 0.0 0.0 1.0
|
||||
|
||||
#pragma parameter inter " Interlace Trigger Resolution :" 400.0 0.0 800.0 25.0
|
||||
|
|
Loading…
Reference in a new issue