A new little shader i did (glsl)

Very nice shader! I try use it with NES SNES, SMD, PS1 games and result is impressive! Constant mask on all different resolutions is great. And it’s quite bright on 1080p LCD screen with fake 1440p overscan settings. Would be great to have Vulkan version of this shader

2 Likes

Doesn’t it already work on Vulkan?

Ehhh, glsl isn’t really for vulkan. (Like glsl ports to slang/Vulkan pretty easily-ish, but it’s not Vulkan)

I mean there might be a slang version of this shader down now, but ik the thread was originally for a glsl shader.

3 Likes

Well glsl works on all devices, but there is a point. If someone uses vulkan e.g. so he can use latest guest.r shader, he could just switch to this shader hypothetically let’s say for some specific format (say Atari 2600), without needing to change settings, restart etc.

2 Likes

Maybe I don’t know something, but when I setup retroarch driver as Vulkan output in Shaders option only possible load slangp presets not glslp. So I switch driver in retroarch to gl and load your shader preset. PS Your shader is really nice - crisp look an accurate.

2 Likes

Been a while since I posted in this thread, @DariusG this is still my favorite lightweight glsl shader. I went and took another stab at tweaking it:

shaders = "5"
shader0 = "shaders_glsl/sharpen/shaders/fast-sharpen.glsl"
wrap_mode0 = "clamp_to_border"
mipmap_input0 = "false"
alias0 = ""
float_framebuffer0 = "false"
srgb_framebuffer0 = "false"
shader1 = "shaders_glsl/dithering/shaders/gdapt/gdapt-pass0.glsl"
filter_linear1 = "false"
wrap_mode1 = "clamp_to_border"
mipmap_input1 = "false"
alias1 = ""
float_framebuffer1 = "false"
srgb_framebuffer1 = "false"
scale_type_x1 = "source"
scale_x1 = "1.000000"
scale_type_y1 = "source"
scale_y1 = "1.000000"
shader2 = "shaders_glsl/dithering/shaders/gdapt/gdapt-pass1.glsl"
filter_linear2 = "false"
wrap_mode2 = "clamp_to_border"
mipmap_input2 = "false"
alias2 = ""
float_framebuffer2 = "false"
srgb_framebuffer2 = "false"
scale_type_x2 = "source"
scale_x2 = "1.000000"
scale_type_y2 = "source"
scale_y2 = "1.000000"
shader3 = "shaders_glsl/misc/image-adjustment.glsl"
filter_linear3 = "true"
wrap_mode3 = "clamp_to_border"
mipmap_input3 = "false"
alias3 = ""
float_framebuffer3 = "false"
srgb_framebuffer3 = "false"
shader4 = "shaders_glsl/crt/shaders/crt-consumer.glsl"
wrap_mode4 = "clamp_to_border"
mipmap_input4 = "false"
alias4 = ""
float_framebuffer4 = "false"
srgb_framebuffer4 = "false"
CONTR = "0.100000"
STEPS = "5.000000"
ia_black_level = "0.020000"
blurx = "0.450000"
blury = "0.250000"
corner = "0.020000"
smoothness = "100.000000"
scanlow = "4.000000"
scanhigh = "6.000000"
beamhigh = "1.250000"
Shadowmask = "6.000000"
slotmask = "0.500000"
slotwidth = "3.000000"
double_slot = "2.000000"
glow = "0.100000"
Size = "0.100000"
sat = "1.000000"
contrast = "1.100000"
WP = "-50.000000"
vignette = "0.000000"

Edit: Tweaked a bit more and it looks like the “Glow Size” parameter acts like a sharpening setting, after lowering that I went from this:

To this:

I posted new settings above, shader also looks smoother with Bilinear Filtering on in the video settings.

Edit 2: I went and sharpened things up a bit more so now it went from this:

To this:

New settings above. You also must have Bilinear Filtering on in the Video settings when using this shader. I use this preset specifically for Yaba Sanshiro and Mupen64plus on my Shield since those two cores are the only ones that run fast in gl driver mode only.

Edit 3: Made some new settings as of 11/16/2022

shaders = "5"
shader0 = "shaders_glsl/sharpen/shaders/adaptive-sharpen.glsl"
wrap_mode0 = "clamp_to_border"
mipmap_input0 = "false"
alias0 = ""
float_framebuffer0 = "false"
srgb_framebuffer0 = "false"
shader1 = "shaders_glsl/dithering/shaders/gdapt/gdapt-pass0.glsl"
filter_linear1 = "false"
wrap_mode1 = "clamp_to_border"
mipmap_input1 = "false"
alias1 = ""
float_framebuffer1 = "false"
srgb_framebuffer1 = "false"
scale_type_x1 = "source"
scale_x1 = "1.000000"
scale_type_y1 = "source"
scale_y1 = "1.000000"
shader2 = "shaders_glsl/dithering/shaders/gdapt/gdapt-pass1.glsl"
filter_linear2 = "false"
wrap_mode2 = "clamp_to_border"
mipmap_input2 = "false"
alias2 = ""
float_framebuffer2 = "false"
srgb_framebuffer2 = "false"
scale_type_x2 = "source"
scale_x2 = "1.000000"
scale_type_y2 = "source"
scale_y2 = "1.000000"
shader3 = "shaders_glsl/misc/image-adjustment.glsl"
filter_linear3 = "true"
wrap_mode3 = "clamp_to_border"
mipmap_input3 = "false"
alias3 = ""
float_framebuffer3 = "false"
srgb_framebuffer3 = "false"
shader4 = "shaders_glsl/crt/shaders/crt-consumer.glsl"
wrap_mode4 = "clamp_to_border"
mipmap_input4 = "false"
alias4 = ""
float_framebuffer4 = "false"
srgb_framebuffer4 = "false"
STEPS = "5.000000"
ia_monitor_gamma = "2.500000"
ia_saturation = "1.200000"
ia_luminance = "0.900000"
ia_black_level = "0.010000"
ia_B = "1.050000"
ia_SHARPEN = "1.000000"
blurx = "0.000000"
blury = "0.250000"
corner = "0.020000"
smoothness = "100.000000"
scanlow = "5.000000"
beamhigh = "0.850000"
brightboost2 = "0.800000"
Shadowmask = "6.000000"
slotmask = "0.700000"
slotwidth = "3.000000"
double_slot = "2.000000"
glow = "0.150000"
Size = "0.100000"
sat = "1.000000"
contrast = "1.200000"
WP = "-75.000000"
vignette = "0.000000"
6 Likes

Yeah it looks good, especially on some old formats like 8bit consoles/computers (e.g. Zx spectrum looks really close to an old TV). I use it as default there myself. Personally I think gdv-mini is more sophisticated even if it has less code and is lighter.

2 Likes

Yeah I haven’t used that one in a while, I can’t do Slot Mask the way I want on that one though so that’s a huge pass from me. Gotta have my Slot Mask

Giving extra likes here after trying these shaders out a bit more. Very good considering the light load, while still having some flexibility with the options. Downside here is the restriction to glsl.

3 Likes

Yeah totally, GDV-Mini really looks great and handles non integer scale quite well, all while being fast and only one pass.

I have a version of GDV Mini in slang in the Mega Bezel, I’ll try to get it committed as a regular shader in the repo soon.

@DariusG what would you say the main difference is between Gdv-Mini and crt-consumer?

5 Likes

They use a different filter, crt-consumer tries to emulate an old TV connection like composite, while gdv-mini is more like an arcade monitor. Crt-consumer is heavier with more options too. Some of them, the light ones, migrated to gdv-mini too.

Some formats like NES, SNES or 8bit computers just feel at home with the crt-consumer filter artifacts.

4 Likes

I converted DariusG’s gdv-mini to slang, you can find it in shaders/shaders_slang/crt/crt-gdv-mini.slangp

5 Likes

Could you do the same for CRT-consumer? Edjt: Convert it to slang that is. Glsl doesn’t work on glcore.

1 Like

I’ll put it in my backlog, but I’m not sure when I might get to it

No worries. The gdv mini with the blargg filter does pretty well anyway. I’m using a small Linux handheld (RG552) so it gets close enough. It’s just that because it’s on glcore the glsl shader can’t load at all.

1 Like

Hi. Can someone tell me how to use these shaders in Duckstation? I tried applying them but Duckstation just gives an error saying “Failed to Launch” or whatever.

A log would get to the root of the issue much faster.

Did a new tweak to my favorite lightweight glsl shader:

https://www.mediafire.com/file/d0h5w1nbfujrmim/crt-consumer-slotmask.glslp/file

Last post I recommended Bilinear Filtering to be turned on in the video settings, this time it should be off when using this preset.

4 Likes

Did a small update to slang version so it’s closer to glsl version, added vignette and the 2 masks missing, the glsl version brightboost (the brighter a color is the brighter boost it gets) and saturation.

4 Likes

Added glow (borrowed from crt-consumer) and white point to gdv-mini, calibrated colors to nearly match my Trinitron, so did a new shader called gdv-mini-ultra-trinitron, added to the repository so it’s soon to be available in SLANG.

Initial

gdv-mini-ultra

6 Likes