Filtering games with 2D and 3D elements

The second to last shot with vivi looks amazing

Nothing beats scanlines imo.

It would be cool to have it use super xBR instead of classic xBR since for environments, superxbr pretty much rendered xBR obsolete. Classic xBR works great for NES and games with more defined colors, but it doesn’t work well with photorealistic environments the same way super xBR does.

Yes, and I have already released the shaders you’re talking about:

  • super-2xbr-3d (for use with 2x internal res);
  • super-4xbr-3d (for use with 4x internal res).

They’re already in common-shaders.

[QUOTE=Hyllian;33988]Yes, and I have already released the shaders you’re talking about:

  • super-2xbr-3d (for use with 2x internal res);
  • super-4xbr-3d (for use with 4x internal res).

They’re already in common-shaders.[/QUOTE]

I’m trying to get these to work. I tried using the presets(those containing 3d) but they don’t load for some reason. I can load for example “super-xbr-2p.cgp” just fine and it got me thinking if I could just rename “super-2xbr-3d-pass0.cg” and “super-2xbr-3d-pass1.cg” to “super-xbr-pass0.cg” and “super-xbr-pass1.cg” they should load when I try using the preset “super-xbr-2p.cgp” but nope, they don’t. So I updated the shaders using the online updater(to reset) and tried to do it manually and it does say “super-2xbr-3d-pass0.cg” under “Shader #0” etc but I don’t see anything different, it’s behaving as if I have zero filters.

I tried them with Mednafen-PSX with the latest nightly build & everything up to date. Resolutions I tried with were 640x480 & 1280x960. (2x & 4x native res iirc).

I’m not sure what I’m missing.

[QUOTE=pralinen;34311]I’m trying to get these to work. I tried using the presets(those containing 3d) but they doesn’t load for some reason. I can load for example “super-xbr-2p.cgp” just fine and it got me thinking if I could just rename “super-2xbr-3d-pass0.cg” and “super-2xbr-3d-pass1.cg” to “super-xbr-pass0.cg” and “super-xbr-pass1.cg” they should load when I try using the preset “super-xbr-2p.cgp” but nope, they don’t. So I updated the shaders using the online updater(to reset) and tried to do it manually and it does say “super-2xbr-3d-pass0.cg” under “Shader #0” etc but I don’t see anything different, it’s behaving as if I have zero filters.

I tried them with Mednafen-PSX with the latest nightly build & everything up to date. Resolutions I tried with were 640x480 & 1280x960. (2x & 4x native res iirc).

I’m not sure what I’m missing.[/QUOTE]

Run it with Retroarch_debug.exe and copy here the log (enable log to level3 in Retroarch options). The log will appear at the command window. Probably your GPU doesn’t support the number of registers needed to run these shaders (they’re very heavy!).

Ah, I had to enable “Logging Verbosity” as well.

RetroArch [INFO] :: CG: Destroying programs. RetroArch [INFO] :: CG: Destroying context. RetroArch [INFO] :: [Cg]: Vertex profile: gp5vp RetroArch [INFO] :: [Cg]: Fragment profile: gp5fp RetroArch [INFO] :: Loading Cg meta-shader: D:\Spel\retroarch\shaders\shaders_cg\xbr\super-2xbr-3d-2p.cgp RetroArch [INFO] :: Found #pragma parameter Xbr - Edge Strength p0 (XBR_EDGE_STR) 2.000000 0.000000 5.000000 0.500000 RetroArch [INFO] :: Found #pragma parameter Xbr - Filter Weight (XBR_WEIGHT) 1.000000 0.000000 1.500000 0.050000 RetroArch [INFO] :: Found #pragma parameter Xbr - Filter Weight2 (XBR_WEIGHT2) 1.000000 0.000000 1.500000 0.050000 RetroArch [INFO] :: Found #pragma parameter Xbr - Anti-Ringing Level (XBR_ANTI_RINGING) 0.000000 0.000000 1.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Xbr - WP1 (WP1) 2.000000 -20.000000 20.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Xbr - WP2 (WP2) 1.000000 -20.000000 20.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Xbr - WP3 (WP3) -1.000000 -20.000000 20.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Xbr - WP4 (WP4) 4.000000 -20.000000 20.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Xbr - WP5 (WP5) -1.000000 -20.000000 20.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Xbr - WP6 (WP6) 1.000000 -20.000000 20.000000 1.000000 RetroArch [INFO] :: Found #pragma parameter Window Sinc Param (JINC2_WINDOW_SINC) 0.420000 0.000000 1.000000 0.010000 RetroArch [INFO] :: Found #pragma parameter Sinc Param (JINC2_SINC) 0.920000 0.000000 1.000000 0.010000 RetroArch [INFO] :: Found #pragma parameter Anti-ringing Strength (JINC2_AR_STRENGTH) 0.000000 0.000000 1.000000 0.100000 RetroArch [INFO] :: Loading Cg shader: “D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg”. RetroArch [ERROR] :: CG error: The compile returned an error. RetroArch [ERROR] :: Fragment: D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(236) : error C1008: undefined variable “XBR_WEIGHT2” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(236) : error C1008: undefined variable “XBR_WEIGHT2” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(236) : error C1008: undefined variable “XBR_WEIGHT2” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(236) : error C1008: undefined variable “XBR_WEIGHT2” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(96) : error C1008: undefined variable “WP1” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(96) : error C1008: undefined variable “WP2” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(96) : error C1008: undefined variable “WP3” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(96) : error C1008: undefined variable “WP4” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(96) : error C1008: undefined variable “WP5” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(96) : error C1008: undefined variable “WP6” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(101) : error C1008: undefined variable “WP4” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(101) : error C1008: undefined variable “WP1” D:\Spel\retroarch\shaders\shaders_cg\xbr\shaders/super-xbr/super-2xbr-3d-pass0.cg(101) : error C1008: undefined variable “WP3”

RetroArch [ERROR] :: Failed to load shaders … RetroArch [INFO] :: CG: Destroying programs. RetroArch [INFO] :: [Cg]: Vertex profile: gp5vp RetroArch [INFO] :: [Cg]: Fragment profile: gp5fp RetroArch [INFO] :: Loading stock Cg file. RetroArch [WARN] :: [GL]: Failed to set multipass shader. Falling back to stock.

Compile errors? Hm…

Thanks for the log. I have indeed made a mistake letting some debug vars inside the shaders (LOL). Amazing how you’re the first one to notice it after more than one week after the release.

Anyway, I just fixed, please download these shaders from common-shaders and test again.

1 Like

Yup, it’s working now

I noticed some weird “glitches” with the font in FF9, see screenshot. I used “super-4xbr-3d-6p-smoother.cgp” preset. It also happened with “super-4xbr-3d-4p.cgp”

My GPU is a GTX 680.

I even have the same problem with pralinen with 750 ti in opengl. Only the super-xbr 3d ones are the problem that doesn’t load. The rest of your 3d shaders are fine, as 1x size. They look awesome, and it kinda effects on non integer textures to an extent, on psx games that runs on 512x240.

[QUOTE=pralinen;34318]Yup, it’s working now

I noticed some weird “glitches” with the font in FF9, see screenshot. I used “super-4xbr-3d-6p-smoother.cgp” preset. It also happened with “super-4xbr-3d-4p.cgp”

My GPU is a GTX 680.[/QUOTE]

I’d need to investigate it. For now, use the super-2xbr-3d instead.

The 4xbr ones were a bit tricky to implement. Maybe I have introduced some bug. I’ll need some time to figure out why it happens.

This is weird that the super-xbr 2x 3d doesn’t work and give same errors with updated shaders, latest nightly builds, or drivers for gtx 750 ti, but it works on geforce gt 430 with slightly outdated drivers. The gpu can load the shaders fine. I don’t know if it depends on the RA version, but I might’ve used the stable 1.3 or builds from few weeks ago on htpc. Both cards are using opengl.

Different drivers can indeed have an effect. Programming for GPUs is a constant hassle like that.

New preset combining 2x internal res with bilateral shader. It works great with psx games with 2D backgrounds and 3D models. fast-bilateral-super-2xbr-3d-3o.cgp is on repo. Screens using 2x internal res on beetle core:

2 Likes

That looks great! The 2D and 3D elements look like they belong together for a change :slight_smile:

Yeah! The difference of this new preset from the first ones in this thread is that now the bilateral is used to clean up jpg artifacts. Most psx games have dirty backgrounds. BTW, the preset is in denoisers folder.

2 Likes

Any chance to make Hyllian’s xBR 3D work on Dolphin?

Does it not work right now?

I’ve tried it with Resident Evil 3 on Native, 2x, 3x, 4x, with FTF on and off, nothing. Also, texture boundaries of Force Texture Filtering still need to be fixed. I guess fixing FTF first would at least make the game playable, excluding audio stutter problem.