xBR algorithm tutorial

I dont remember how I got them, but I prefer these, they make the backgrounds most rounded and clean I think. Maybe you can tell me why they are so different?

Not a big difference. Just a bit less rounded. If you like old version, keep it.

A new version called xbr-lv2-small-details.cg released today. It’s less harsh to dithering and textures in general.

Small-details: Standard: Small-details: Standard:

1 Like

Hello Hyllian, big fan of your work

I have request, can you please release a modified version of your “super-8xbr-3d-6p.glslp” with a bit sharper and lighter colors similar to “scalefx-hybrid.glslp” , here are pics of your “super-8xbr-3d-6p.glslp” and “scalefx-hybrid.glslp” at native

I wish I didn’t had to bump this thread as I’m unable to PM. That being said, I am one of a g’mic developer and I’m looking to add pixel art scaling tool to g’mic-qt so that gimp and krita users could get easy access to the tool. It is not clear what @Hyllian means by this

For that reason, from now on, all algorithm terms will be related to the down-right edge. You’ll have to apply the same rules to the other three edges by symmetry.

I know that you have to apply the same rules, but what condition should there be for accepting one edge or the other edge? Max difference?

You should see the shaders on Retroarch repository. There you’ll see the conditions. This tutorial is outdated.

Anyway, I’m back working on super-xbr shaders. After some years I decided to see its parameters and figured out I should change some of them. At the same time, I ported Anime4k hlsl shaders to cg and it work well after super-xbr by doing an slightly dilation and using gradients to enhances edges.

Some screens (super-xbr + anime4k):

Full size: https://img.onl/iFJbhA

Full size: https://img.onl/2Z3Gc7

Full size: https://img.onl/etEksE

Full size: https://img.onl/6jIuBM

Full size: https://img.onl/NyawaY

Full size: https://img.onl/2cIkTs

https://img.onl/zFbFDE

https://img.onl/N9czm5

https://img.onl/rTJEp

Oh wow, are these in your PS3 pack in the other thread, as well? I’ve tried to port the GLSL version to RA, but it was ~30 passes -_-

These screenshots look awesome, btw.

EDIT: also, did you do the proposed FXAA step (presumably between steps 4 and 5)?

No, RA 1.0.0.2 for PS3 can’t run. I’m using my old notebook to run them. They’re 11 passes! 2x3 sxbr + 1x1 catmull-rom + 1x4 anime4k passes. I didn’t use FXAA.

These anime4k shaders are the old ones in hlsl. They’re very simple. I like the layer it apply to the whole screen. It works by making a gentle dilation just before a push in edge gradients. I didn’t push it too much, because the effect can degrade in “xylograph” very fast.

I’ll let here a version without further optimizations if you’re interested in test:

super-xbr-6p-anime4k cg shaders and preset - beta

The super-xbr shaders on RA repo are using outdated params, so I have included the new ones.

1 Like

Great job on the shader Hyllian, if I may suggest to add some sort of noise effect to give the render a bit of “density” look instead of the “clay/wax” look .

See album

This is something to add, indeed. Though it should be an independent shader implemented on its own pass. The same way as anime4k is just a separated filter (a sharpening-like method), which can be used with any other.

Glad you’re considering the idea . Here is a preset I modified ,it works well for games with big sprites such as fighting games but it lacks the thin edges your xbr-Anime4k preset provide , it would be great to have the best of both worlds . Use it with vulkan render (it’s very hardware demanding)

https://mega.nz/file/YMBDxAII#5UXt5jzIhfFII2P3c3pwoGgF_6id4lU64kOCn74No3k

Here is an album for the preset I have posted , I like how the details are maintained and how the color graduate. On the other hand , edges and colors vibrance/fidelity leaves more to be desired:

Too many shaders there! kkk I doubt it doesn’t degrade image at some point.

A gentle sharpening method after an upscaling is recommended. But you are using so many sharpeners that the textures were chewed multiple times. It has created some kind of mosaic.

Yeah , I figured as much :sweat_smile: .I was going for close to ESRGAN sort of look Which is pretty much down right Impossible. sharping the NEDI3 too much gives an ugly artifacts which I masked with slow-bilateral. With your xbr-Anime4k that won’t be necessary.

Another day, another port. :wink:

Finesharp is another good sharpening shader I ported to Retroarch. It’s good because it only sharp fine edges and don’t touch small color transitions of backgrounds and textures. It works well with super-xbr-small-details.

I’ve made some tweakings on sxbr parameters to work well with finesharp. This preset works by preserving fine detail pixels and smoothing out only those clearly edges. And finesharp enhance visuals by sharpening relevant edges.

Download here (cg only): super-xbr-3p-small-details + finesharp shaders

Shader tip: Do you wanna unleash Nedi 3-pass preset power? Try swapping nedi-pass2 by super-xbr-small-details-pass2 (set param edge_strength_p2 = 0.0) and see what happens (experiment on action games like Demon’s Crest, Megaman, Maximum Carnage or Dracula XX, where small text details aren’t relevant).

1 Like

You can get some impressive results with nedi + sxbr-pass2:

Preset: https://anonymousfiles.io/Gl50rcLC/

1 Like

oh lawd, dat actraiser 2 final boss shot :open_mouth:

nedi 's signature is a little strong for my tastes at full res, usually, but those downsampled thumbnails look really fantastic.

2 Likes

Indeed. NEDI is a rough beast for little details, it needs to be tamed to work with small resolutions, kkk. I think the 3-pass swap works on that way. Maybe there are other forms to improve this even further.

But, believe me, for action-paced games where you don’t need to pay atention to small details, that preset is very good. It cleanup the whole screen and give a better sensation of movement. Still screens aren’t good measures for that preset.

1 Like