This would be a breakthrough for CRT emulation. As of right now, no currently available display is bright enough to do full-strength masks and scanlines AND black frame insertion, so you’re always compromising on one thing or another. If we can fake SDR content as HDR content then we’d have all the brightness we need for all the CRT effects. No one seems to know how to make this work, though. Maybe a bounty is in order…
If you want to maintain CRT-like brightness, you need a minimum of 800 nits if you want BFI @ 120 Hz and full strength mask and scanlines- that would leave you with about 100 nits. If you want to do the slotmask, you need to start with 1600 nits(!), so that might still be out of reach for even the brightest displays currently available. You’d have to reduce the slotmask strength while using BFI and scanlines.
Here’s a new version of the Bezel Reflection shader
I’ve separated out the scaling into an include file hsm-mega-screen-scale.h which defines user parameters and can be used by the shaders in the chain which need to match scale including:
CRT Shader
Integer Scale
Bezel Overlay Scale
Scaling of Reflection
Some of the stuff the screen scale does:
Aspect Ratio
Integer Scale or non integer scale
Vertical Scanlines
Horizontal Integer scale for vertical scanlines
Crop Overscan to allow you to crop and properly affect the integer scale
Integer scale multiple offset to make the screen smaller or bigger if needed
Small scaling offset so it can be adjusted just a small amount on top of the integer scale
There are two presets included, one for horizontal or vertical. The bezel is oversized so that it will work at multiple aspect ratios and resolutions
To use this you must to set your video settings aspect ratio to your monitor resolution aspect ratio and integer scale to off, since the shader handles the aspect ratio and integer scale.
This is slower than the last version because it is done as additional passes on top of the CRT shader. The reason it was done this way was so that it can be integrated more easily on top of other CRT shaders.
The version of Guest’s crt shader here is a copy from last month with alterations to use the shared scaling method, screen distortion & overscan crop. Thanks Guest for this awesome Shader!
In terms of what’s left to do, there are a few things:
*The shader probably needs some optimization, it’s slower than the old version
Auto generation of the bezel.@Syh’s suggestion with the shadertoy example (https://www.shadertoy.com/view/MljXDG) are a great idea and I’ll probably try this out. This is because getting the inner edges of the bezel to correctly match the screen curvature when creating the bezel graphics is one of the more frustrating parts of the process
Add static noise on top of the reflection for surface texture reflectance variation which help with the realism you can see a shadertoy of something like this here https://www.shadertoy.com/view/lt2SDK
Improve the reflection approaching the corners because right now there is a point where it cuts off
Add the tight reflections in the corners to be driven by the bezel reflection
Need separate reflection brightness control over for the top, bottom and sides
Let me know what you think about it and if you have any problems on any hardware especially non NVidia hardware because that’s what I’m testing on.
I also wanted to add a big thanks to @hunterk who helped my with his expertise along the way!
Ive noticed that dark colours like blues and purples dont seem to cast a reflection at all, look at the TMNT intro the dark purple doesnt seem to be reflected at all and then on Afterburner on the night stage the dark blue on the horizon doesnt seem to cast a reflection either. I feel even though these are dark colours they would still cast a reflection as the tube is still pushing out light even through dark colours
At least for the TMNT screen, I’m pretty sure I can make out the purple reflection it just blends really well into the bezel (probably because of the darkness of the color or something, some one with a better understanding of color theory then myself would probably know why).
Maybe we need some kind of saturation/brightness boost for the bezel reflection glow.
Hey @BlockABoots & @Syh, there are some parameters you can play with in the settings for brightness, gamma, contrast & saturation. If you set all these parameters to 1.0 you will get a reflection which has the same brightness of the screen.
It’s possible that the default for contrast is too high, or the way I’m doing contrast is making coolers mid range brightness colors too dark.
The contrast & Gamma are there mostly because in a number of reference images of CRTs it seems the brighter colours show up more.