Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the needed menu settings to set the new RetroArch CRT Beam Simulation shader #245

Open
Monkee-code opened this issue Jan 15, 2025 · 0 comments

Comments

@Monkee-code
Copy link

Retroarch 1.20.0 has integrated the groundbreaking CRT rolling scan simulation shader for flat screens created by Mark Rejhon from BlurBusters and Timothy Lottes, the creator of the original FXAA shader and the crt-lottes shaders.

This is only for screens >=120hz but for all kinds of modern screen technologies (best results are with OLED 240Hz+) and it delivers impressive fluidity without the usual BFI flaws (less flicker, less dim, prevents image-persistence, allow arbitrary refresh rates).

It's a shader but not the same kind we are used to and can/should actually be combined with a classic CRT shader.
You can find the beam shader in the shaders_slang/subframe-bfi, named “crt-beam-simulator.slangp.
If you’d like to combine this shader with others (classic CRT shaders), you can prepend it to other presets.
You can also select any of the pre-made presets that use the CRT beamracing shader. You can find these under shaders_slang/presets/crt-beam-simulator.

To set this up, we need the following options in RetroBat:

Already available in RB:
RA Settings > Video > Synchronization > Gsync/Freesync Compatibility OFF
RA Settings > Video > HDR > OFF works better in most cases
RA Settings > Video > Output > Video > Vulkan

Needs to be added:
RE Settings > Core > Allow Cores to Switch the Video Driver > OFF. This shader (and shader sub-frames) only works with Vulkan so it's important to NOT allow the cores to chose their driver.
RA Settings > Video > Synchronization > Shader Sub-frames > ON and choose the option that matches your monitor’s refresh rate.
(The “Rolling Scanline Simulation” option do NOT need to be added because it was a previous implementation that is miles behind what we now have).

There are also shader parameters that one need to be able to tweak to adapt to screen particularities:
Brightness vs Clarity: trade-off between brightness and motion clarity, for 120 Hz monitors (2 subframes), a value of ~0.5 works well, while ~0.7 is ideal for 240 Hz monitors (4 subframes).
Gamma: use it to achieve a neutral image (i.e., eliminating any unusual dark lines)
LCD Anti-Retention On/Off : used to avoid image retention but useful only for some LCD screens, this does create lag though so it's important to have the choice to disable this for OLED or LCDs not affected.

Reminders of Best Practices from the creator himself
Disable VRR
Try both HDR and SDR, usually SDR works best
Disable ABL (or lower Brightness-vs-Blur to stay within linear ABL window)
Recalibrate your black and white levels to avoid clipping (creates banding)
Readjust Gamma to match gamma curve
Set display profile to "sRGB"
If you're doing picture adjustments, do it before the beam simulator. Avoid all picture adjustments in NVIDIA Control Panel and in Windows .icc calibration profiles.
If you still have banding, try switching CRT filter shaders, and/or turning off CRT filters.
If using LCD, try out odd-number native:emulated Hz ratios
Use blurry pixels and scanlines instead of sharp square pixels, it will hide the jelly effect better.

For troubleshooting information, see Solutions to Known Issues [Banding, Color Ghosting, Erratic Flicker]
For more information about the shader, see crt-beam-simulator.slang

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant