Koko-aio shader discussions and updates

I spent some time on this, because that colorization is not achievable with my implementation.

To understand why, I blindly tuned koko-aio as i would do normally:
So, by taking the bright hue and the dark hue, as explained here

…then i feeded tuned koko-aio and dmg.slangp with a dumb black to white gradient and found that the problem lies here:

koko-aio down: linearly fades hue and brightness without clamping at all.

dmg.slangp up: it clamps the dark for the first 10%, then starts to fade, but while the brightness fades linearly, the hue stays versus the blue for longer, it is not linear at all.
I don’t know why it acts that way, but it doesn’t look right to me.

Koko-aio maps the input grayscale picture from the core linearly to a hue gradient defined by hue-bright and hue-dark parameters, and optionally shifts the gradient edges to one of the two hues via the bias parameter:

The following are the default colors i copied from internet pictures of real hardware:

Here I tuned some color parameters to better match what you asked, but i don’t remember any blue tint on original gameboy honestly:

As you can see, the color shifting from the yellow background to the blueish foreground is different, less steep. Those are the parameter changed over the default gameboy preset just in case:

brightness 0.12
contrast -0.29
hue bright: 0.17 
hue dark: 0.55
saturation: 1.10
Grid strength: 0.20

For gb mono color, unfortunately color schemes are not supported, you can still use the coloring done by the core itself, why not?

I tested my implementation again with gb pocket mono, by taking an online shot from a real gameboy:

Then I found the bright hue and the dark hue and reported them in koko-aio; this required a bias adjust, adjusted brightness/contrast/saturation by gut:

brightness -0.10
contrast -0.25
hue bright: 0.25
hue dark: 0.14
hue bright-dark bias: -0.58
saturation: 0.24
9 Likes

That was really in depth, thanks. I will try the gb pocket parameters, it looks really good in your sample.

1 Like

You’re welcome!

bg picture would need to be adapted or zoomed to hide the yellow background; also, I activated the rounded corners under curvature section (without warping ofc)

That looks promising. Preset has already been released?

Which one?

Greenish Gameboy mono with overlay is in the dev repo, bluish and pocket ones are not.

2 Likes

Hi Kokoko3k - your “FXAA Sharp” presets are an absolute marvel, exactly what I was looking for, I love them - I wanted to ask you if you also had a smooth version of these presets planned and how could I go about applying the background you have in the “ambient immersive” presets to these - phenomenal work, maybe I finally don’t have to change computers to have the visual effect I wanted with retrogaming (the PS2 emulation on my Mini-PC is still heavy) - thank you very much for this stratospheric result that you share with us.

1 Like

P.S. My request comes from the fact that, in particular, your FXAA Sharp NTSC Selective preset is perfect for Megadrive games but gives problems with Super Nintendo games, having a version that is smooth without using NTSC would be the icing on the cake.

1 Like

You’re too kind…

FXAA sharp presets can be smoothed by just moving Sharp X in the glow section from -1.0 to something higher, try around -0.65 for box blur or around 1.0 for gauss.

You can also try to do the same with Sharp Y, but due to current implementation, that could lead to some artifacts in high contrast zones, try…

The immersive preset draws a big bezel and …a colored room around the game, leaving not much space to draw the scanlines properly; this means that the coolest masks you see in other presets would produce moiree at least on 1080p, and would need higher resolutions to work properly.

You can try to resize the window to see what I mean.

For this very same reason (maximize game area), I made all NG presets with a wider bezel; but yes, I can see if I can make another immersive preset with a different mask, but don’t expect miracles.

1 Like

Screenshots or it is a lie :stuck_out_tongue:

1 Like

No no seriously, I love this result, it doesn’t do anything about the ambient preset, the result is too good to miss. I’ll immediately show you a screenshot of Mario World where I encountered the problem.

2 Likes

Basically you need to copy any parameter in the ambient light, bezel and background image sections to the preset you want to be ‘immersive’. (I hope to not forget anything)

1 Like

I’ll look into this; meanwhile, you can start to enable “Phase shift” to mitigate a bit.

1 Like

Starting from the Monitor_FXAA_Sharp_Core_SlotMask preset and changing only the SharpX value to - 065

1 Like

I find it perfect, I think I created the smooth version of your Monitor_FXAA preset. Of course you are the creator and master, let me know what you think

Looks good!

You can manually copy the mask (low level phosphorgrid parameters) from the ntsc preset that gives bad artifacts on the letters. maybe it has a nicer mask, your choice!

1 Like

In summary, in my opinion by setting your preset “Monitor_FXAA_Sharp_Core_SlotMask” and changing the value “Sharp X : - 0.65” you practically get the smooth version of your preset. And with this I can emulate the whole world with the results I want, you basically took me to heaven. If you could find a way to mitigate the effects of your “TV_FXAA_NTSC_Selective” preset on Super Nintendo games I personally wouldn’t ask anything else, I’d be set for life really. It would be the icing on the cake, at least I would also have a shader that emulates Vintage TVs with what comes from it. In the meantime, I’ll show you a screen shot of my smooth variant. Thank you very much, they should name streets and squares here in Italy with tour name.

I love that I can choose between Sharp and smooth.

Smooth

Sharp

2 Likes

Of course, and I close, I know I’m worn out but it’s the enthusiasm that your incredible work causes me, if you have your own settings to create your own “Monitor_FXAA_Smooth” preset and publish it it would be fantastic to try. In the meantime I’m enjoying these shaders, thanks again.

1 Like

About to merge this; artifacts do not spread anymore and are diagonally shifted along the y axis now:

Tv-NTSC_Generic-FXAA_sharp-Selective.slangp

–EDIT

Will be up in minutes.

1 Like

Show !!! Thank you so much for your spectacular work!

1 Like