New CRT shader from Guest + CRT Guest Advanced updates

It doesn’t work correctly. It changes colors other than black. This is how it should look (image-adjustment.slang with black level 0.3):

But this is what you get in crt-guest-advanced:

It would seem the only color that should be touched is pure black? (RGB 000.) Maybe taking a look at what image-adjustment.slang does helps?

Edit:
This is the reference image for easier testing with the RA image viewer:

loht-220702-230643

2 Likes

Dunno, in the images @Tatsuya79 posted there was an obvious change in saturation, which results if you substract an amount of a ‘grayscale’ color. Other colors seems to be affected to by the negative amount.

Substracting from the black color wouldn’t do much since negative values get clamped to the 0.0-1.0 range or, in some other cases, produce odd results. Reducing grayscale colors is an option, but i can’t tell if it would do anything consistent without some better logic.

1 Like

I uploaded the reference image. You can look for yourself how it looks in the RA image viewer with image-adjustment.slang.

2 Likes

Grade also has a black level setting that seems to work just as good. It’s been ported over to guest advanced and can be swapped in by replacing the “pre-shaders-afterglow” pass with the one in the guest/advanced/grade folder.

2 Likes

So it’s not possible to do this with the existing “black level” setting?

2 Likes

I’m not sure as I’ve never used it personally. From some quick tweaking though the black level in grade also has a minus setting that really makes blacks black

2 Likes

Which game is that in the photo? I’d like to try the grade black level on it

2 Likes

The arcade version of “Legend of Hero Tonma” (running in FBNeo.) But you can use the reference image from above because you can’t pause the game on that screen and it only lasts for a couple seconds.

3 Likes

Can’t make it work (using the fast preset.) I replaced:

shader2 = shaders/guest/fast/pre-shaders.slang

with:

shader2 = shaders/guest/advanced/grade/pre-shaders-afterglow-grade.slang

But it fails to load with:

ERROR] [slang]: Texture name ‘AfterglowPass’ not found in semantic map, Probably the texture name or pass alias is not defined in the preset (Non-semantic textures not supported yet)

However, I can replace

shader0 = shaders/guest/fast/stock.slang

with the image-adjustment.slang shader. That works.

3 Likes

New Release Version (2022-07-02-r2):

Notable changes:

  • ‘Raise Black Level’ parameter now allows negative values, mostly to improve contrast with some games. There are nice examples in the discussion a bit above.
  • It’s a smarter implementation than in previous version, allowing deviations on grayscale tones, which might be caused by color alterations, also provides better contrast on near-grayscale tones which a game could provide (contra arcade…).

Download link:

https://mega.nz/file/Q5ARVajT#yuKw9Uhl3gzSr0d5RIDTzU6qEQvjwcW9JwAW68DANqI

7 Likes

I never use the fast version but I just tried to replace that pass with the grade one and also got a failed error, I don’t think it’s usable with the fast versions. I know for a fact it works with both guest advanced and ntsc versions though

1 Like

It’s still wrong xD In fact, it’s way worse than before. You could cheat your way out of it before by raising brightness. Now you can’t do that.

It isn’t wrong, it’s very useful for some games, maybe you should give it another try.

Here’s what it looks like now:

You can’t fix that look. Here’s how it looks with shader0 replaced with image-adjustment.slang:

And this is the arcade PCB of the game with its CRT monitor:

(From this video)

1 Like

Maybe at max settings. :wink: I like it how it works now though. Don’t want to do a simple cutoff on grayscale, that’s too retarded. :neutral_face:

2 Likes

Isn’t that what “black level” is though? This setting looks more like “darkness enhancement”, not “black level” :stuck_out_tongue: Emulating a custom CRT monitor with a completely different black level seems to be what’s needed.

Black levels aren’t (this) negative with any model i heard of. It’s a more of a QOL enhancers for some games.

Ofc. shader parameters can be cranked up, but you can use like as this also:

The image adjustment implementation messes with saturation, it’s a simple substractive implementation with some correctures.

One has to be a bit specific here, or feedback can become very confusing.

2 Likes

Hi, I’m new here, I love this post, and You are Doing a Good Job, I think is the best Shader in retroarch. here I’m gonna post some pics in 4K

. This is how it looks. I tried to copy my 14" CRT Sanyo TV…

6 Likes

I can’t make it look good, no matter what I try :stuck_out_tongue: The main issue is preserving the relative brightness between things. The simple black level adjustment from image-adjustment just works better for me:

After changing black level in the image-adjustment.slang settings, I can then use the guest advanced settings for bloom, contrast, etc and I get what seems to be an accurate result. The castle is bright, the mountain underneath is darker, the stone walls are brighter… This matches the brightness differences from the photo of the arcade machine. In your screenshot, everything has the same brightness. It’s very flat.

3 Likes

Here Another example…

:grinning:

3 Likes