Koko-aio shader discussions and updates

koko-aio NG-1.4 has been released and submitted for merging into retroarch official repo, should be available soon via online updater.

Note on updating
Before running the shader online updater, I suggest you to delete bezel/koko-aio.
This ensures that no stale shaders/presets/files will pollute the folder.

Changelog:

Misc

  • Xbox/d3d compatibility: add specific workarounds, enable them by editing config/config-static.inc
  • New config/config-static.inc and config/config-user.txt files. Use them to change static parameters or tu turn runtime parameters into static ones and gain performance. Keep a backup before updating, ofc.

Presets

  • Mitigate glitch patterns in Generic-Handheld-RGB.slangp
  • Add two handhelds dotmatrix presets “dots” in uncorrected aspect and 4:3 aspect
  • Wider ambientlight in generic handhelds rgb preset
  • Tweaked ambientlight on gba night preset
  • GBA preset: Switched from dotmatrix to pixelgrid
  • Reduce spot power on immersive preset
  • Add a simple immersive fxaa preset in the old 4.1 folder
  • Updated overmask presets to include unsharp-mask+FXAA and moire mitigation
  • New preset Monitor-Screen_Hmask_WideR-Screen_SlotMask

Parameters

  • Removed GEOM_CUT_EARS parameter, useless since using my curvature now
  • Add moire mitigation option
  • Allow to define ambientlight wideness for rotated games
  • Allow to switch to fake integer scanlines, always or only on interlaced screens (see docs)
  • Haloing can happen on an already “scanlined” image if a new static parameter: HALO_PRE_SCANLINE_GAP
  • Remove Inter-cell extra steepness parameter; it has been never used and has very little effect
  • Vertical cell Mask->Vertical shift: negative values will select the sharpest line when using screen coords

Fixes/Changes

  • Bloom strength on white area was broken when using content geometry override, fixed
  • Mitigate clipping on bright background images when mixing ambilight over them
  • Disable ambientlight debanding grain/noise when using a background image
  • Recentered wx mask so that phosphor falls at the center
  • Fixed textures paths in handhelds presets
  • Give halo a slight (very slight) rounder look
  • Slightly optimized pixel_blank_alternate (still statically disabled)
  • Dedot: use green as main channel
  • Move DYNZOOM_FACTOR in the static config file
  • Switch TATE mode to Auto by default, should affect all the presets

Performance

  • Modified debanding code, should be a bit faster now
  • Found a bottleneck in the vignette/spot code; small speedup
  • Since we gained some fps, switch HALVE_BORDER_UPDATE to 0.0 by default
  • small optimization to ntscdec()
12 Likes

@kokoko3k do you have contact with Batocera Linux developers? It has become my main emulation system…but it uses a closed Retroarch version without online updater and the koko-aio version there is a bit older. No need to say that I got a little disappointed because I loved newer koko-aio versions. Can you send them this latest update to integrate on Batocera 39 when it gets a stable version?

1 Like

Hi there,

I’m no in contact with Batocera devs, but from their build scripts, it seems they are stuck at Jul 29, 2023.

It seems they won’t need any submission tho, as they will hopefully just fetch the updated retroarch shaders when they will release a new version by just switching the commit hash.

So you just have to wait a bit.

Meanwhile I think you can safely get the latest koko-aio and put it alongside the Batocera shaders.

Does that work?

Unzip (and delete the sceenshots folder), Use Filezilia to connect to your box, and copy the new shaders (folder) into /usr/share/batocera/shaders/crt

then use putty to connect to your box and run “batocera-save-overlay”, this will save the new shaders.

I use Batocera Linux.

Don’t do anything else, or you migt break your install.

2 Likes

With some tweaks to user config file (statically disabled bezel,curvature and some other things i won’t use anyway on the phone) and delta render active (enabled in static config file to save on battery on static content), my Galaxy s10 can handle this at 720p without audio underruns.

Gba is another fine target.

Android compresses screenshots too much, this is the Base.slangp preset without any tweaks other than statically disabling things and Delta render, also, PUAE core has been set to lowres to keep gpu usage lower:

I was expecting more from this device, I guess it is showing its age.

Your S10 should be much more powerful than my retroid pocket :sweat_smile: But I guess Amiga is much harder to emulate. Also I really like these new overmask shaders they look so good with fxaa

1 Like

Indeed, but it is not a matter of core… I’ve the same performance with easier ones, like Megadrive :confused:

Not exactly, I tried copying the files but they wont work, no matter i tried to adjust folders etc. but there must be another way, that i’m not aware

I didn’t understand very well, were you able to load the shaders this way?

New Fxaa sharp preset worth adding (added) to dev repo:

Presets-ng/Monitor-FXAA_sharp-Screen_SlotMask.slangp

An this one too: Monitor-New_aperturegrille_gm.slangp

11 Likes

I use Batocera in the same PC i use Windows. Is there some way to update the shaders directly from Batocera F1 file manager?

This is Great.

Personally, I like presets that mix some pixelated appearance with a little softness more. These softer ones may be better in games on systems after 16bits

5 Likes

No, you didn’t understand. I use bootable Batocera Linux on the same PC that I also use Windows. So, all access to the ext4 file system I do directly through Batocera Linux using the key F1 file manager

1 Like

If you need help with Batocera, the best place to ask for it is in the Discord. @lbrpdx and @TVsIan are two of the main devs. @Modhack is very well versed in getting external shaders working in Batocera.

4 Likes

thx @kokoko3k for all your hard work, i had just made up some modifications to yours presets to accommodate them to my own preferences, this is monitor slotmask with prepend it ntsc, manual mask with swapped phosphors to be bgr and no curvature to avoid moire pattern over at 1080p,

5 Likes

Which koko-aio presets have you had the best experience with for N64, PS1 and Dreamcast? If possible with screenshots please

No experienge with PS1, but with N64 and Dreamcast, screenshots can’t be good.

This is because being the output interlaced, the shader emulates the flickering of scanlines and alternates (so blends) them over time; you have to check those “scanlined” presets by yourself.

Eg: the following does NOT look that way if you see it live:

—but there are some presets that skip scanlines, so I can show them

tv-aperturegrille-bloom-bezelwider

tv-slotmask-bloom-bezelwider

tv-PAL-my-old:

(psx 1x internal resolution -> not interlaced)

4 Likes

@alexb3d:

I’m currently trying to write my own implementation of dedithering.

When it works good I achieved this:

Good results:

The code is very generic, and can catch checkerboards, orizontal and vertical dithering patterns. It is not perfect (and never will be), but I’ve something in mind still to try.

meh results…:

Not so good results, but this is very hard:

8 Likes

Nice. I like this resurgence of tweaking the ntsc look by everyone lately. Looks like you’re going for both a sharp and smooth look here.

2 Likes

I liked the style, it reminded me of the Genesis. And it looks sharp.

Although, on PC it is “slightly” different. I figured it out, it’s the “Moire” monitor option. This rotates the mask and creates a pixel sweep, this can’t be done on flat monitors, but the shader option is quite similar.

Here’s what it does with Eartwork Jim.
1 only tvout-jinc-sharpen (without scanlines). 2 tvout-jinc-sharpen with the option tvout composite. 3 Append crt-easymode-halation.

PC has different graphics standards and each has various modes. For example, has analog RF connection but it is different from that of a console, Interlaced, high resolution, low, everything. And the patterns sometimes are not even patterns, they are spots or star points.

Look Hercules: Note that the pattern on the floor is different from the pattern on the wall.
Same: 1 only tvout-jinc-sharpen (without scanlines). 2 tvout-jinc-sharpen with the option tvout composite. 3 Append crt-easymode-halation.

Or CGA, something similar happens.

EGA is more tremendous, because it has I don’t know how many modes, the native EGA game mode, and an EGA interleaved one for use with VGA cards with EGA games and… too many.

I almost forgot. What color profile do you have on your monitor? The image you sent me looks different in RetroArch.

3 Likes